Hi,
I've a question on awk. In English I want to:
(a) open a file, (b) search through the file for records where length of field15 > 20 characters and (c) print out some fields in the record.
I've written the following and it works OK. The trouble is this will ALWAYS write out the column... (5 Replies)
I'd like to define an alias to awk's begin statement since I use awk with different delimiters all the time and it is tiresome to type awk '{OFS="\t";FS="\t"}{BLAH BLAH}' every time. The problem is that bash won't let me make an alias with an open quote, which is necessary for the BEGIN alias to... (3 Replies)
I am beginner in awk
awk 'BEGIN{for(i=1;(getline<"opnoise")>0;i++) arr=$1}{print arr}'
In the above script, opnoise is a file, I am reading it into an array and then printing the value corresponding to index 20. Well this is not my real objective, but I have posted this example to describe... (1 Reply)
Here's the command I'm running:
# echo "hi" | awk '{etime = system("hostname") ; close("hostname") ; print etime""}'
And here's the ouput:
server.domain.tld
0
Why in the world is that second line, the one that's just "0", there? Many thanks in advance. (2 Replies)
I'm new to awk, trying to understand the basics.
I'm trying to reset the counter everytime the program gets a new file to check.
I figured in the BEGIN part it would work, but it doesn't.
#!/bin/awk -f
BEGIN {counter=0}
{
sum=0
for ( i=1; i<=NF;... (1 Reply)
Hi,
I have written below script to begin if the line has n
#!/bin/ksh
/usr/xpg4/bin/awk {/ n / 'BEGIN {X = "01"; X = "02"; X = "03"; X = "04";
X = "05"; X = "06"; X = "07"; X = "08";
X ="09"; X = "10"; X = "11"; X = "12"; };}
NR > 1 {print $1 "\t" $5 "," X "," $6 " " $7}'} input.txt |... (9 Replies)
Hello,
I need a little help with the following:
I'm using AWK to read input from a comma-seperated value file, and only printing certain fields like so:
awk -F "," '{print $1,$3,$6}' /list.csv | tail -1
Which outputs the following:
server1 APPID OS
I run into a problem... (8 Replies)
DOCKER(1) General Commands Manual DOCKER(1)NAME
docker - System tray for KDE3/GNOME2 docklet applications
SYNOPSIS
docker [options]
DESCRIPTION
This manual page documents briefly the docker command. This manual page was written for the Debian distribution because the original pro-
gram does not have a manual page.
docker is a docking application (WindowMaker dock app) which acts as a system tray for KDE3 and GNOME2. It can be used to replace the panel
in either environment, allowing you to have a system tray without running the KDE/GNOME panel.
Docker was written and designed to work with Openbox 2, but it should work fine in any window manager that supports WindowMaker dock apps.
OPTIONS -h-help
Show summary of options.
-display DISPLAY
The X display to connect to.
-border N
The width of the border to put around the system tray icons. Defaults to 1.
-vertical
Line up the icons vertically. Defaults to horizontally.
-wmaker
WindowMaker mode. This makes docker a fixed size (64x64) to appear nicely in in WindowMaker. Note: In this mode, you have a fixed
number of icons that docker can hold.
-iconsize SIZE
The size (width and height and height) to display icons as in the system tray. Defaults to 24.
-color COLOR
The background color to use for the tray. Defaults to whatever color the window manager specifies.
AUTHOR
This manual page was written by Ari Pollak <ari@debian.org>, for the Debian GNU/Linux system (but may be used by others).
November 2, 2002 DOCKER(1)