I made a mistake in the expression echo -e '. $1\necho var' >script.sh
I fixed it and you probably just copied it before that
It will be right echo -e '. $1\necho $var' >script.sh
--- Post updated at 17:15 ---
Quote:
Originally Posted by cmccabe
should script.sh look like:
if this line is from script then it is not correct $1=config # define argument
positional parameters are defined as
Or did you mean that when starting a script, the first parameter is defined $1 == config
Last edited by nezabudka; 01-05-2020 at 09:25 AM..
Guys im using bash and for me i think its the best shell, anyway which conf file related to bash ? is it $SHELL or .profile i want to add path to it so i dont need to type the full path of the binary file, i also want to configure the behaviour of the shell, please help. (1 Reply)
okay i'm going to try to say this uber-simple:
I use dropbox (file-sync service). in order for dropbox sync files, they must be its children eg. somewhere under /home/jzacsh/Dropbox].
I want to now use it to keep my development files in sync across my machines:
easy: just move my dev. files... (2 Replies)
Hi I am new to shell scripting. There is a requirement to write a shell script to meet follwing needs.Prompt reply shall be highly appreciated.
script that will compare two config files and produce 2 outputs - actual config file and a report indicating changes made.
OS :Susi linux ver 10.3.
... (4 Replies)
Hi ,
I have a config _file that has 3 columns (Id Name Value ) with many rows . In my bash script i want to be able to parse the file and do a mapping of any Id value
so if i have Id of say brand1 then i can use the name (server5X) and Value (CCCC) and so on ...
Id Name ... (2 Replies)
myscript.sh
#!/bin/bash
ARGA=$1
if ; then
echo "${ARGA}:Confirmed"
else
echo "${ARGA}:Unconfirmed"
fi
when I run the above script from the command line, i run it as:
./myscript.sh jsmith
now some times, i need to runn it this way: (8 Replies)
Dear Unix gurus,
We have a config shell script file which has 30 variables which needs to be passed to master unix shell script that invokes oracle database sessions. So those 30 variables need to go through the database sessions (They are inputs) via a shell script. one of the variable name... (1 Reply)
Dear Unix gurus,
We have a config shell script file which has 30 variables which needs to be passed to master unix shell script that invokes oracle database sessions. So those 30 variables need to go through the database sessions (They are inputs) via a shell script. one of the variable name... (1 Reply)
I want to make a config file which contain all the paths.
i want to read the config file line by line and pass as an argument on my below function.
Replace all the path with reading config path line by line and pass in respective functions.
how can i achieve that?
Kindly guide.
... (6 Replies)
Hello,
My question is about curl command. (ubuntu14.04)
In terminal, I am able to download my mainfile with:
curl -u user1:pass1 http://11.22.33.44/*******
When I convert it into bash script like this:
#!/bin/bash
cd /root/scripts
computer_ip=11.22.33.44
curl -u $1:$2... (8 Replies)
Discussion started by: baris35
8 Replies
LEARN ABOUT OPENSOLARIS
gphoto2-config
gphoto2-config(1) User Commands gphoto2-config(1)NAME
gphoto2-config - return meta information about installed version of libgphoto2(3).
SYNOPSIS
gphoto2-config [--prefix=DIR] [--libs] [--cflags] [--help] [--version]
DESCRIPTION
gphoto2-config is a convenience script which retrieves information about the installed version of libgphoto2(3) on your system.
gphoto2-config is typically used to compile and link against libgphoto2(3). The following example shows how to use gphoto2-config in a
Makefile:
program: program.c
cc program.c `gphoto2-config --cflags --libs`
The output is similar to that produced by pkg-config(1).
OPTIONS
The following options are supported:
--cflags
Prints pre-processor and compile flags required to compile with libgphoto2(3) on the command line.
--help
Displays help and usage information.
--libs
Identical to --cflags option but only prints the link flags.
--prefix=DIR
Specify a different prefix from the default libgphoto2(3). (default is/usr).
--version
Displays version of libgphoto2(3) installed on your system.
FILES
The following files are used by this application:
/usr/bin/gphoto2-config Executable for installed library helper script
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWgnome-camera-devel |
+-----------------------------+-----------------------------+
|Interface stability |Volatile |
+-----------------------------+-----------------------------+
SEE ALSO attributes(5), pkg-config(1), libgphoto2(3)NOTES
Written by Matt Keenan Sun Microsystems Inc., 2008.
SunOS 5.11 01 Aug 2008 gphoto2-config(1)