I do a
echo $1, it prints out what is the default login shell used.
echo $2 onwards, all I get is a newline. Why is that?
$1 (or $2,$3 ...) is supposed to be the arguments given to some script.
Here's an example script:
And the example output
$1 is the argument passed for shell script.
Suppose, you run
In your case $1 prints default login shell used because this argument was passed to script that runs your login shell. But if you'll write and run your own script in current session, $1, $2, ... will be parameters that you send to your script.