-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
61 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
// Access the command line arguments passed to the script | ||
const inputParam = process.argv[2]; // process.argv[0] is 'node', argv[1] is the script path | ||
|
||
// Check if an argument was provided | ||
if (!inputParam) { | ||
console.error("No parameter provided! Please pass a parameter as an argument."); | ||
process.exit(1); // Exit with a non-zero code to indicate an error | ||
} | ||
|
||
// Log the provided parameter to the console | ||
console.log(`The provided parameter is: ${inputParam}`); |