Sponsored Content
Top Forums UNIX for Advanced & Expert Users Place the results of a CUT command into a variable Post 302891750 by talonbow on Friday 7th of March 2014 05:23:08 PM
Old 03-07-2014
No, its not a homework assignment

This is a small part, and the easiest part, of fully automating a BAR File deployment.

The script I am writing will access a product called REMEDY to extract a deployment ticket, it will then automatically extract the code from a software repository called StarTeam, it will then FTP the code to Servers and perform an automated deployment of a BAR file.

The file that will be passed will contain much more information than what was indicating, including (but not limited to) the StarTeam project name, View Labels, BAR and TAR files to be deployed, Target Servers and Directories, and other information.

The information that I provided was a small part of the process and only involved with verifying and removal of the old Execution Group Directory.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Setting the Results of a Command to a Variable

Hi, Hi, I run the command: hostname to get the host back from the server: db201 Now, I need to take that result and set it to a variable. Can anyone help me with this?? I need to be able to use the same script on multiple servers so I do not want to hardcode the hostname result into... (1 Reply)
Discussion started by: stky13
1 Replies

2. UNIX for Dummies Questions & Answers

Cut Command value assign to variable

Hi, I am new to UNIX Scripting. I have been trying to use the CUT command to retrieve part of the header from a file and assign it to a variable. I have tried searching a lot, but I am still unsuccessful. Sample Header: HJAN BALANCE 20090616 I need to retrieve the date here, which always... (10 Replies)
Discussion started by: ragz_82
10 Replies

3. Shell Programming and Scripting

Extract and place in variable

If i wanted to extract the number of collisions from the eth0 section of the ifconfig file and have the output placed in a variable how would i do this? I can get the output displayed using: /sbin/ifconfig eth0 | grep "collisions" What command would i now use to place the output in a... (1 Reply)
Discussion started by: warlock129
1 Replies

4. Shell Programming and Scripting

Place 'find' results within TeX command

Hi, In an effort to collect all my .java-files and place them in a LaTeXfile (using the listings environment of latex), i tried to use ex. So what i have now is: find . -name "*\.java" > latex ex latex <<HERE %s/\(.*\)/\\lstinputlisting{\1} wq HERE So i try to escape the '\' with... (1 Reply)
Discussion started by: HannesBBR
1 Replies

5. Shell Programming and Scripting

Cut text file in place

I have a file that i want to take only the first part of it and discard the rest, to be accurate,I need the first 137097 lines but I cant use split because I dont have enough space on my disck. I need sth to cut the file in its place (3 Replies)
Discussion started by: Heidi Heweidy
3 Replies

6. Shell Programming and Scripting

sed and cut command in variable

hi, i want to remove 12 and 13 column from psv files and dump them in new folder ls -ltr *GTDA_Dly_Pmix_*.psv>filename.xls var1=`cat filename.xls` for i in $var1 do var3=`echo "$i" |cut -d '|' -f12,13 |sort -u` sed -e 's/"|$var3"//g... (2 Replies)
Discussion started by: renuk
2 Replies

7. Shell Programming and Scripting

Storing command output in a variable and using cut/awk

Hi, My aim is to get the md5 hash of a file and store it in a variable. var1="md5sum file1" $var1 The above outputs fine but also contains the filename, so somthing like this 243ASsf25 file1 i just need to get the first part and put it into a variable. var1="md5sum file1"... (5 Replies)
Discussion started by: JustALol
5 Replies

8. UNIX for Beginners Questions & Answers

Results of ldapsearch piped to grep are cut off

ldapsearch -x -LLL -E pr=200/noprompt -h abc-loc.somecompany.com -D "account@somecompany.com" -w password -b "cn=groupname,ou=Resource,ou=groups,dc=abc,dc=somecompany,dc=com" | grep member Results are: member: CN=Hanson\, Joe,OU=End Users,OU=Accounts,DC=abc,DC=somecompany,DC=com member:... (3 Replies)
Discussion started by: who10
3 Replies

9. Shell Programming and Scripting

Use cut output as variable piped awk command

Hi, I would like use the output of my cut command as a variable in my following awk command. Here's what I've written. cut -f1 info.txt | awk -v i=xargs -F'' '{if($6 == $i) print $20}' summary.txt Where obviously the 'xargs' doesn't do what I want. How can I pass my cut result to my awk... (3 Replies)
Discussion started by: heyooo
3 Replies

10. Shell Programming and Scripting

I want to add a variable for the results from the formula of one variable and results of another var

Good morning all, This is the file name in question OD_Orders_2019-02-19.csv I am trying to create a bash script to read into files with yesterdays date on the file name while retaining the rest of the files name. I would like for $y to equal, the name of the file with a formula output with... (2 Replies)
Discussion started by: Ibrahim A
2 Replies
asadmin-deploydir(1AS)						   User Commands					    asadmin-deploydir(1AS)

NAME
asadmin-deploydir, deploydir - deploys an exploded format of application archive SYNOPSIS
deploydir --user admin_user[--password admin_password][--host localhost] [--port 4848] [--secure|-s] [--passwordfile filename] [--terse=false] [--echo=false] [--interactive=true] [--virtualservers virtual_servers] [--contextroot context_root] [--force=true] [--ver- ify=false] [--precompilejsp=false][--name component_name] [--uniquetablenames=true | false] [--dbvendorname dbvendorname] [--createta- bles=false | --dropandcreatetables=false] dirpath Deploys the exploded format of the application archives present under the directory provided as the command operand. The deployed format, of EAR or WAR applications, reside on the application server and have a directory structure which can be used for deployment. The --force option makes sure the component is forcefully (re)deployed even if the specified component has already been deployed or already exists. Set --force to false for a first deployment. If the application with that name is running, and force is set to false, the command fails. If the --uniquetablenames, --createtables, and --dropandcreatetables options are not specified, the entries in the deployment descriptors are used. This command is supported in remote mode only. OPTIONS
--user authorized domain application server administrative username. --password password to administer the domain application server. --host machine name where the domain application server is running. --port port number of the domain application server listening for administration requests. --secure if true, uses SSL/TLS to communicate with the domain application server. --passwordfile file containing the domain application server password. --terse indicates that any output data must be very concise, typically avoiding human-friendly sentences and favoring well- formatted data for consumption by a script. --echo setting to true will echo the command line statement on the standard output. --interactive prompts you for the required options that are not already specified. --virtualservers comma separated list of virtual server IDs. --contextroot valid only if the archive is a web module. It is ignored for other archive types; defaults to filename without extension. --force makes sure the component is forcefully (re)deployed even if the specified component has already been deployed or already exists. --precompilejsp by default is set to false which does not allow the JSP to pre-compile during deployment. Instead JSPs are compiled during runtime. --verify if set to true, the syntax and semantics of the deployment descriptor is verified. --name name of the deployable component. --uniquetablenames guarantees unique table names for all the beans and results in a hashcode added to the table names. This is useful if you have an pplication with case-sensitive bean names. --dbvendorname name of the database vendor being used. Default is the corresponding entry in the cmp-resource () element of the sun-ejb-jar.xml file. If not specified, the default is SQL92. Thereby the DDL files to create and drop tables will be generated in SQL92 format. --createtables creates tables during deployment for applications using unmapped CMP beans. Default is the corresponding entry in the cmp-resource element of the sun-ejb-jar.xml file. If not specified, defaults to the entries in the deployment descriptors. --dropandcreatetables drops existing tables and creates tables during deployment for application using unmapped CMP beans. If not speci- fied, the tables will be dropped if the drop-tables-at-undeploy entry in the cmp-resource element of the sun-ejb- jar.xml file is set to true. The new tables are created if the create-tables-at-deploy entry in the cmp-resource element of the sun-ejb-jar.xml is set to true. On redeploy the tables created by the previous deploy are dropped before creating the new tables. OPERANDS
dirpath path to the directory containing the exploded format of the deployable archive. Example 1: Using deploydir asadmin> deploydir --user admin --passwordfile passwords.txt --host localhost --port 4848 --force=true --precompilejsp=true /home/temp/sampleApp Command deploydir executed successfully Where: theexploded application to be deployed is in the /home/temp/sampleApp directory. EXIT STATUS
0 command executed successfully 1 error in executing the command asadmin-deploy(1AS), asadmin-undeploy(1AS), asadmin- enable(1AS), asadmin-disable(1AS), asadmin-list-components(1) J2EE 1.4 SDK March 2004 asadmin-deploydir(1AS)
All times are GMT -4. The time now is 03:29 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy