02-01-2019
Quote:
When you want to give thanks to a member for their help, please click on the "thumbs up" icon in the post(s) you want to thank them.
Everyone here appreciates a bit of thanks for their work.
Gave a thumbs up as well. Definitely appreciate the feedback and excellent discussion.
This User Gave Thanks to user052009 For This Post:
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I have a variable which consists of a string like this:
001 aaabc 44 a bbb12
How do I extract each substring, delimited by the spaces, into new variables - one for each substring?
eg var1 will be 001, var2 will be aaabc, var3 will be 44, var4 will be a, etc?
I've come up with this:... (2 Replies)
Discussion started by: Sniper Pixie
2 Replies
2. Shell Programming and Scripting
Hello,
I am an intermediate scripter. I can usually find and adapt what I need by searching through previous postings, but I'm stumped.
I have a string with the format "{Name1 Release1 Type1 Parent1} {Name2 Release2 Type2 Parent2}". It is being passed as an argument into a ksh script. I need to... (5 Replies)
Discussion started by: drd_2b
5 Replies
3. UNIX for Dummies Questions & Answers
I have a UNIX shell where:
LEVEL=dev
SITE=here
and WHEREIAM=/tmp/$SITE/location/$LEVEL
I want to echo $WHEREIAM in such a way that I get it back with all the environment variables resolved (/tmp/here/location/dev).
This command will be used in a shell script. (5 Replies)
Discussion started by: zambo
5 Replies
4. Shell Programming and Scripting
Hi all,
I'm trying to extract the name of a script that is being run with a full path. i.e.
if the script name is /some/where/path/script_name.ksh
I'd like to extract only: script_name
i know that it is possible to do so in two phases:
echo "${0##*/}" will give me script_name.ksh
and... (4 Replies)
Discussion started by: iceman
4 Replies
5. Shell Programming and Scripting
In a bash script I've set a variable that is the directory name of where an executable lives.
the_dir=`dirname $which myscript`
which equates to something like "/path/to/dir/bin"
I need to cut that down to remove the "bin" so I now have "/path/to/dir/".
This sounds easy but as a... (2 Replies)
Discussion started by: Witty
2 Replies
6. Shell Programming and Scripting
Hello,
I have a paramter $param consisting just of two literals and want to split it into two parameters, so I can combine it to a new parameter <char1><string><char2>, but the following code didn't work:
tmp_PARAM_1=cut -c1 $PARAM
tmp_PARAM_2=cut -c2 $PARAM... (2 Replies)
Discussion started by: ABE2202
2 Replies
7. Shell Programming and Scripting
Hi All,
I am facing a problem and I am not able to solve it.
I have already searched google, but nothing (maybe I am not using the correct key words).
As a database query result, I have a file like below:
fmv:/home/fmv/tmp>cat TestBackRef.txt
/^TEST\(\{4\}\)X\{12\}Y\.txt$/\0#\1/#Test... (2 Replies)
Discussion started by: felipe.vinturin
2 Replies
8. Shell Programming and Scripting
Hi,
I need to convert string "(joe.smith" into "joe_smith"
i.e. I need to remove the leading opening brace '(' and replace the dot '.' with an under score '_'
can anyone suggest a one liner ksh script or unix command for this please (3 Replies)
Discussion started by: sdj
3 Replies
9. Shell Programming and Scripting
Hi all,
I have used a bash script which ultimately converts a string into date using date --date option:
DATE=$DATE" "$TIME" "`date +%Y` //concatenating 2 strings
TMRW_DATE=`date --date="$DATE" +"%s"` //applying date command on string and getting the unixtime
Please use code tags... (7 Replies)
Discussion started by: Rashu123
7 Replies
10. Shell Programming and Scripting
Hi, I have a variable with grep output like this:
WORDS=$(grep -r -c -i -E "palindrom" /"$DIRECTORY"/)
so "echo "$WORDS"" could be:
//directory/file1.txt:0
//directory/file2.txt:0
//directory/file3.txt:3
//directory/file4.txt:1
//directory/file5.txt:0
I need to "sed" my variable... (3 Replies)
Discussion started by: Hornys
3 Replies
LEARN ABOUT DEBIAN
lazygal.conf
LAZYGAL.CONF(5) File formats and conventions LAZYGAL.CONF(5)
NAME
lazygal.conf - Configuration file for lazygal, a static web gallery generator.
DESCRIPTION
The configuration file is an INI like file which configures lazygal. The format looks like this:
[sectionname]
variable = value
othervariable = othervalue
[othersection]
foo = bar
Boolean values can be conveniently set in the following ways:
o For True: 1, yes, true, and on.
o For False: 0, no, false, and off.
Please refer to the python ConfigParser documentation[1] for more information on the file format.
RUNTIME SECTION
The runtime defines the runtime parameters.
quiet
Boolean. Same as --quiet in lazygal(1) if True. (default is False).
debug
Boolean. Same as --debug in lazygal(1) if True (default is False).
check-all-dirs
Boolean. Same as --check-all-dirs in lazygal(1) if True. (default is False).
GLOBAL SECTION
The global defines the global parameters. Those parameters apply to all the sub-galleries.
destdir
Same as --output-directory=DEST_DIR in lazygal(1) (default is current directory).
clean-destination
Boolean. Same as --clean-destination in lazygal(1) if True.
dir-flattening-depth
Same as --dir-flattening-depth=LEVEL in lazygal(1).
puburl
Same as --puburl=PUB_URL in lazygal(1).
theme
Same as --theme=THEME in lazygal(1).
WEBGAL SECTION
The webgal defines the parameters for a web-gallery.
default-style
Same as --default-style=DEFAULT_STYLE in lazygal(1).
webalbumpic-bg
Same as --webalbum-pic-bg=WEBALBUMPIC_BG in lazygal(1).
webalbumpic-type
Same as --webalbum-pic-type=WEBALBUMPIC_BG in lazygal(1). If you set this to 'tidy' you may also consider setting webalbumpic-size (see
below) to something smaller than the default 200x150.
webalbumpic-size
Size of picture mash-up representing galleries, eg. 200x150.
image-size
Same as --image-size=IMAGE_SIZE in lazygal(1).
thumbnail-size
Same as --thumbnail-size=THUMBNAIL_SIZE in lazygal(1).
thumbs-per-page
Same as --thumbs-per-page=THUMBS_PER_PAGE in lazygal(1).
sort-medias
Same as --pic-sort-by=ORDER in lazygal(1).
sort-subgals
Same as --subgal-sort-by=ORDER in lazygal(1).
original
Boolean. Same as --original in lazygal(1) if True (default is False).
original-baseurl
Same as --orig-base=RELATIVE_PATH in lazygal(1).
original-symlink
Boolean. Same as --orig-symlink in lazygal(1) if True (default is False).
dirzip
Same as --make-dir-zip in lazygal(1) if True (default is False).
jpeg-quality
Same as --quality=QUALITY in lazygal(1).
jpeg-optimize
Boolean. Run an extra optimization pass for each generated thumbnail if True, the default.
jpeg-progressive
Generate progressive JPEG images if True, the default.
publish-metadata
Publish image metadata if True, the default: copy original image metadata in reduced picture, and include some information in the image
page.
TEMPLATE-VARS SECTION
The template-vars defines the custom template variables. The variables and their value are listed in this section.
Example 1. $footer in the default template
For instance, $footer is a template variable in the default template. Its value can be defined with this configuration file:
[template-vars]
footer = <p>All pics are copyright 2011 me</p>
SEE ALSO
lazygal(1).
AUTHOR
This manual page was written for the Debian system (but may be used by others). Permission is granted to copy, distribute and/or modify
this document under the terms of the GNU General Public License, Version 2 any later version published by the Free Software Foundation.
On Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common-licenses/GPL.
COPYRIGHT
Copyright (C) 2011
NOTES
1.
the python ConfigParser documentation
http://docs.python.org/library/configparser.html
lazygal August 2011 LAZYGAL.CONF(5)