xxxxxxxxxx
bash yourscript.sh file1 file2
yourscript.sh
inside script
#!/bin/bash
a=$1 # = to file1
b=$2 # = file2
echo $1
echo $2
xxxxxxxxxx
$ myscript.sh first_arg second_arg
# myscript.sh
#!/bin/bash
echo $1 # output: first_arg
echo $2 # output: second_arg
xxxxxxxxxx
#!/bin/bash
# Save the first argument to a variable
argument1=$1
# Print the value of the first argument
echo "Argument 1: $argument1"
xxxxxxxxxx
$ myscript.sh first_arg second_arg
# myscript.sh
#!/bin/bash
echo $1 # output: first_arg
echo $2 # output: second_arg