A Brief Introduction to Unix-2019-AMS

Total Page:16

File Type:pdf, Size:1020Kb

A Brief Introduction to Unix-2019-AMS Brief Intro to Linux/Unix Brief Intro to Unix (contd) A Brief Introduction to o Brief History of Unix o Compilers, Email, Text processing o Basics of a Unix session o Image Processing Linux/Unix – AMS 2019 o The Unix File System Pete Pokrandt o Working with Files and Directories o The vi editor UW-Madison AOS Systems Administrator o Your Environment [email protected] o Common Commands Twitter @PTH1 History of Unix History of Unix History of Unix o Created in 1969 by Kenneth Thompson and Dennis o Today – two main variants, but blended o It’s been around for a long time Ritchie at AT&T o Revised in-house until first public release 1977 o System V (Sun Solaris, SGI, Dec OSF1, AIX, o It was written by computer programmers for o 1977 – UC-Berkeley – Berkeley Software Distribution (BSD) linux) computer programmers o 1983 – Sun Workstations produced a Unix Workstation o BSD (Old SunOS, linux, Mac OSX/MacOS) o Case sensitive, mostly lowercase o AT&T unix -> System V abbreviations 1 Basics of a Unix Login Session Basics of a Unix Login Session Basics of a Unix Login Session o The Shell – the command line interface, o Features provided by the shell o Logging in to a unix session where you enter commands, etc n Create an environment that meets your needs n login: username n Some common shells n Write shell scripts (batch files) n password: tImpAw$ n Define command aliases (this Is my password At work $) Bourne Shell (sh) OR n Manipulate command history IHateHaving2changeMypasswordevery3weeks!!! C Shell (csh) n Automatically complete the command line (tab) The password speech… [use good passwords] DoIT Password guidelines: TC Shell (tcsh) n Edit the command line (arrow keys in tcsh) https://it.wisc.edu/guides/select-manage-protect-passwords Korn Shell (ksh) n Can log in more than once, in several windows Bourne Again Shell (bash) [OSX terminal] Basics of a Unix Login Session Basics of a Unix Login Session Basics of a Unix Login Session o Logging in to a unix session o Logging off from a Unix session o Changing your password n logout, exit, ^d n passwd (will ask for your old password, then your n Many people can be logged in at the same time via the network n For CentOS Linux, choose System/Log out new one, then new one again to confirm) n Remote login – secure shell [cat3/cat4/cat5.aos.wisc.edu] n In x-windows, click EXIT, right-click in n Windows – SecureCRT or putty (Xming for graphics) background, select logout/exit, try various n If you forget your password – see the systems buttons in the background. n OSX/Linux – from Terminal window administrator, they can change it for you. ssh [email protected] –Y (or –X) n MAKE SURE you are logged out, or others can n Starts in your home directory access your files, do things as you. Also, if the screen locks, others can’t user the machine 2 Basics of a Unix Login Session The Unix File System The Unix File System o Who are you? o What is a file? o Types of files (contd) n id o Types of files .. – A special directory that refers to the n groups – what groups you belong to - Ordinary Files (text, programs, images, etc) parent directory (the one above where you are - Directories (file that holds other files, dirs) n root – the Superuser - administrator now) - Special files (used to represent physical . – A special directory that refers to the devices (printers, disks, etc) - Pipes (temporary file used to hold output from directory that you are in now one command until it is ready to be read by another All directories contain . and .. The Unix File System The Unix File System The Unix File System / o Organized as a heirarchy of directories /bin o Home Directory – where you are when you starting with / (the root directory) /home1 first log in (usually under /home - here, /home1/class/fall06 under /home1/class/fall18) /home1/class/fall06/poker /dev o / is similar to the Windows My o Open Terminal starts in home or /etc Desktop directory Computer, or the Mac Desktop/Finder. /home /home/aos o Current Working Directory (pwd) /home/user1 /lib o Absolute vs Relative Path Names /tmp /home1/class/fall18/poker/dir1/file1 /sbin dir1/file1 3 The Unix File System The Unix File System The Unix File System o Change directory (cd) to dir1 o Common System Directories o Common System Directories (contd) cd dir1 o / - root directory o /usr/include – C include files o /bin – binary executable files o /home/aos– home directory for user aos Now, ways to refer to that same file o /dev – special device files o /tornado/home1/class/fall06/poker – home directory for user poker o /etc – administrative/configuration files/programs o /usr/local – locally added programs, libraries, etc /home1/class/fall18/poker/dir1/file1 o /home – user directories o /usr/local/bin o /lib – libraries used by programs and languages file1 o /tmp – scratch area for temporary files o /usr/local/lib ../dir1/file1 o /usr – system files/directories shared by users ./file1 Using Unix Commands Using Unix Commands Using Unix Commands o Case Sensitive! (ls not the same as Ls or LS) o Use backspace or delete to correct errors o Processes – unique process ID number for stty erase [hit the key you want to every process that is running o The Prompt: where you enter your commands use] o Commands to identify processes agnes[poker] %1 (csh, tcsh) n ps (sh, ksh, bash) agnes$ o Online manual pages for almost all commands n ps –flu poker man man n ps –efl o General command syntax man passwd n ps –aux (bsd type systems) command [-flags] arg1 arg2… man –k compiler 4 Using Unix Commands Using Unix Commands Using Unix Commands o ps –flu poker o Jobs – per shell shortcut of programs running o Killing processes kill pid # ps -flu poker agnes 27% jobs kill –STOP pid F S UID PID PPID C PRI NI ADDR SZ WCHAN STIME TTY TIME CMD [1] + Running firefox kill -9 pid 8 S poker 1047 1 0 99 20 70cb0ec0 155 70cb0f2c o Job Control Jan 16 ? 0:00 /bin/sh ^Z – stop a running job 8 S poker 1049 1048 0 40 20 70ccd5f0 269 7015587a jobs Jan 16 ? 0:00 /var/tmp/lm_TMW12.ld fg %1 8 S poker 1048 1047 0 41 20 70ccceb8 133 70641c1c Jan 16 ? 0:00 sh -c while read line; bg %1 Using Unix Commands Using Unix Commands Using Unix Commands o Typical command locations o PATH environment variable – where linux looks for progs o Locating Programs – whereis, which n /bin agnes 1% echo $PATH n agnes 2% whereis pwd /research/linux_grads/grads-1.9b4/bin: n /usr/bin /research/linux_bin:/research/linux_idv: pwd: /bin/pwd /usr/bin/pwd n /usr/local/bin /research/linux_mcidas/bin: /research/ncl/bin: n agnes 3% which pwd n /home1/class/fall06/poker/bin /usr/local/weather/bin:/usr/local/bin: n /research/linux_bin /bin:/usr/bin:/usr/bin/X11:.: /usr/pwd /research/linux_gempak/GEMPAK7/os/linux/bin agnes 2% rehash agnes 3% ./prog 5 Using Unix Commands Using Unix Commands Using Unix Commands o Several commands can be entered on one o Command History (in C or TC shell) o Command History (in C or TC shell) command line, separated by a ; n history – list previous commands (numbered) n tcsh/bash – arrow keys ls ; date n !! – repeat previous command n up/down to cycle back/forward through command o Use output of one command as input to n !str – repeat previous command beginning with history another – separate by a | str n left/right to edit the command line ls -ltrF | tail n !N – repeat command number N n <ctrl>-a – beginning of line n o Run a command in the background n ^old^new – repeat previous command, replacing <ctrl>-e – end of line firefox & first occurrence of old with new n Dont need to move to end of line before running Using Unix Commands Using Unix Commands Using Unix Commands o o Standard input/output/error from commands Redirecting standard input/output/error o Pipes (the vertical bar | ) (csh/tcsh) n Input – usually the keyboard ls –ltrF | tail n Output – usually the screen > >> >& >>& < << o Aliases – roll your own commands n Error – usually the screen alias ll '/bin/ls –ltrF' ls > file std output overwrites file ls >> file std output appends at end of file alias lt '/bin/ls –ltrF | tail' alias arch 'cd /bigtemp/poker/archive' ls >& file std output/error into file ls >>& file std output/error appended to file o Line Continuation character - \ ls < file std input from file ls << WORD std input until line identical to WORD [WORD must be first and only thing on the line, and unique] 6 Using Unix Commands Using Unix Commands Working with Files and Directories o Line Continuation character - \ o Shell Scripts – group of commands entered o Creating files /bin/rm –r \ one by one in a file, executed as if you had n cat – concatenate files file1 \ typed them at the prompt file2 \ cat > file1 file3 \ this text will be put into file1 file4 #!/bin/csh echo Good Morning, Pete ^D echo Today is `date` echo Remember everything you need to do cat file1 file2 file3 > file4 exit cat file1 file2 > file1 o Used extensively for creating GEMPAK plots [overwrites original file1] Working with Files and Directories Working with Files and Directories Working with Files and Directories o echo – echo commands to stdout (the screen?) o Editing files o Text editors n What is a text editor compared to a word n vi(m) - cryptic text editor included with all unix echo this text will be put processor? n nedit - graphical editor simliar to notepad into file1 > file1 n gedit - another graphical editor n pico/nano - nicer character based text editor n vi, nedit, gedit, nano, pico, emacs echo this text will be n emacs- powerful, customizable text editor appended after the last >> vi file1 o touch – update the modification time of a file, or file1 nedit file1 & create an empty file if it doesnt already exist 7 Working with Files and Directories Working with Files and Directories Working with Files and Directories o Displaying files o Listing files – ls o Copying files - cp n Cat – file scrolls up the screen cat file1 n cp file1 file2 copies file1 to file2 n Pagers (more, less) – pause between screenfuls ls n cp file1 dir1 creates a copy of file1 less file1 a b dir1 file1 in dir1 n Text editors (vi, nedit, pico, emacs) ls –a n cp file1 file2 file3 dir1 n Head – displays the first 10 lines of a file .
Recommended publications
  • Medi-Cal Dental EDI How-To Guide
    ' I edi Cal Dental _ Electronic Data Interchange HOW-TO GUIDE EDI EDI edi EDI Support Group Phone: (916) 853-7373 Email: [email protected] Revised November 2019 , ] 1 ,edi .. Cal Dental Medi-Cal Dental Program EDI How-To Guide 11/2019 Welcome to Medical Dental Program’s Electronic Data Interchange Program! This How-To Guide is designed to answer questions providers may have about submitting claims electronically. The Medi-Cal Dental Program's Electronic Data Interchange (EDI) program is an efficient alternative to sending paper claims. It will provide more efficient tracking of the Medi-Cal Dental Program claims with faster responses to requests for authorization and payment. Before submitting claims electronically, providers must be enrolled as an EDI provider to avoid rejection of claims. To enroll, providers must complete the Medi-Cal Dental Telecommunications Provider and Biller Application/Agreement (For electronic claim submission), the Provider Service Office Electronic Data Interchange Option Selection Form and Electronic Remittance Advice (ERA) Enrollment Form and return them to the address indicated on those forms. Providers should advise their software vendor that they would like to submit Medi-Cal Dental Program claims electronically, and if they are not yet enrolled in the EDI program, an Enrollment Packet should be requested from the EDI Support department. Enrollment forms are also available on the Medi-Cal Dental Program Web site (www.denti- cal.ca.gov) under EDI, located on the Providers tab. Providers may also submit digitized images of documentation to the Medi-Cal Dental Program. If providers choose to submit conventional radiographs and attachments through the mail, an order for EDI labels and envelopes will need to be placed using the Forms Reorder Request included in the Enrollment Packet and at the end of this How-To Guide.
    [Show full text]
  • Process Text Streams Using Filters
    Process Text Streams Using Filters OBJECTIVE: Candidates should should be able to apply filters to text streams. 1 Process Text Streams Using Filters KeyKEY knowledge KNOWLEDGE area(s): AREAS: Send text files and output streams through text utility filters to modify the output using standard UNIX commands found in the GNU textutils package. 2 Process Text Streams Using Filters KEY FILES,TERMS, UTILITIES cat nl tail cut paste tr expand pr unexpand fmt sed uniq head sort wc hexdump split join tac 3 cat cat the editor - used as a rudimentary text editor. cat > short-message we are curious to meet penguins in Prague Crtl+D *Ctrl+D - command is used for ending interactive input. 4 cat cat the reader More commonly used to flush text to stdout. Options: -n number each line of output -b number only non-blank output lines -A show carriage return Example cat /etc/resolv.conf ▶ search mydomain.org nameserver 127.0.0.1 5 tac tac reads back-to-front This command is the same as cat except that the text is read from the last line to the first. tac short-message ▶ penguins in Prague to meet we are curious 6 head or tail using head or tail - often used to analyze logfiles. - by default, output 10 lines of text. List 20 first lines of /var/log/messages: head -n 20 /var/log/messages head -20 /var/log/messages List 20 last lines of /etc/aliases: tail -20 /etc/aliases 7 head or tail The tail utility has an added option that allows one to list the end of a text starting at a given line.
    [Show full text]
  • “Linux at the Command Line” Don Johnson of BU IS&T  We’Ll Start with a Sign in Sheet
    “Linux at the Command Line” Don Johnson of BU IS&T We’ll start with a sign in sheet. We’ll end with a class evaluation. We’ll cover as much as we can in the time allowed; if we don’t cover everything, you’ll pick it up as you continue working with Linux. This is a hands-on, lab class; ask questions at any time. Commands for you to type are in BOLD The Most Common O/S Used By BU Researchers When Working on a Server or Computer Cluster Linux is a Unix clone begun in 1991 and written from scratch by Linus Torvalds with assistance from a loosely-knit team of hackers across the Net. 64% of the world’s servers run some variant of Unix or Linux. The Android phone and the Kindle run Linux. a set of small Linux is an O/S core programs written by written by Linus Richard Stallman and Torvalds and others others. They are the AND GNU utilities. http://www.gnu.org/ Network: ssh, scp Shells: BASH, TCSH, clear, history, chsh, echo, set, setenv, xargs System Information: w, whoami, man, info, which, free, echo, date, cal, df, free Command Information: man, info Symbols: |, >, >>, <, ;, ~, ., .. Filters: grep, egrep, more, less, head, tail Hotkeys: <ctrl><c>, <ctrl><d> File System: ls, mkdir, cd, pwd, mv, touch, file, find, diff, cmp, du, chmod, find File Editors: gedit, nedit You need a “xterm” emulation – software that emulates an “X” terminal and that connects using the “SSH” Secure Shell protocol. ◦ Windows Use StarNet “X-Win32:” http://www.bu.edu/tech/support/desktop/ distribution/xwindows/xwin32/ ◦ Mac OS X “Terminal” is already installed Why? Darwin, the system on which Apple's Mac OS X is built, is a derivative of 4.4BSD-Lite2 and FreeBSD.
    [Show full text]
  • Unix/Linux Command Reference
    Unix/Linux Command Reference .com File Commands System Info ls – directory listing date – show the current date and time ls -al – formatted listing with hidden files cal – show this month's calendar cd dir - change directory to dir uptime – show current uptime cd – change to home w – display who is online pwd – show current directory whoami – who you are logged in as mkdir dir – create a directory dir finger user – display information about user rm file – delete file uname -a – show kernel information rm -r dir – delete directory dir cat /proc/cpuinfo – cpu information rm -f file – force remove file cat /proc/meminfo – memory information rm -rf dir – force remove directory dir * man command – show the manual for command cp file1 file2 – copy file1 to file2 df – show disk usage cp -r dir1 dir2 – copy dir1 to dir2; create dir2 if it du – show directory space usage doesn't exist free – show memory and swap usage mv file1 file2 – rename or move file1 to file2 whereis app – show possible locations of app if file2 is an existing directory, moves file1 into which app – show which app will be run by default directory file2 ln -s file link – create symbolic link link to file Compression touch file – create or update file tar cf file.tar files – create a tar named cat > file – places standard input into file file.tar containing files more file – output the contents of file tar xf file.tar – extract the files from file.tar head file – output the first 10 lines of file tar czf file.tar.gz files – create a tar with tail file – output the last 10 lines
    [Show full text]
  • How the /Etc/Passwd File Relates to the Laua User
    Page 1 (2) System Foundation 9.0 laua User and Group How the /etc/passwd File Relates to the laua User Scenario Most users who need access to the Lawson environment will need to have a user account set up on the Operating System where Lawson System Foundation 9.0 has been installed. Users will need resources allocated to run their jobs and space in the directory structure to store their print files. The user account on the Operating System is what allows the allocation of resources and space. In the example presented in this session, users are associated to the Unix Operating System and setup via the /etc/passwd file. The information stored on the user account in the file is used by Lawson’s Legacy Security System, laua. This scenario will present the /etc/passwd file and highlight the important parts of the user represented in the file and how it relates to user setup. Workflow Step 1 of 3: To verify that a user has an account on the Unix Operating System where the Lawson server resides, view the /etc/passwd file on the Lawson server. To do so, you must first access a command line which can be done either through LID (Lawson Insight Desktop) or through lawterminal which is command line access through the Lawson portal. This demonstration will use LID. First access your command line. Action: Type in 'cd /etc' and press the 'Enter' key. © Copyright Lawson Learning 2008 Page 2 (2) Step 2 of 3: You can use any method you choose to view the file.
    [Show full text]
  • The Linux Command Line
    The Linux Command Line Fifth Internet Edition William Shotts A LinuxCommand.org Book Copyright ©2008-2019, William E. Shotts, Jr. This work is licensed under the Creative Commons Attribution-Noncommercial-No De- rivative Works 3.0 United States License. To view a copy of this license, visit the link above or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042. A version of this book is also available in printed form, published by No Starch Press. Copies may be purchased wherever fine books are sold. No Starch Press also offers elec- tronic formats for popular e-readers. They can be reached at: https://www.nostarch.com. Linux® is the registered trademark of Linus Torvalds. All other trademarks belong to their respective owners. This book is part of the LinuxCommand.org project, a site for Linux education and advo- cacy devoted to helping users of legacy operating systems migrate into the future. You may contact the LinuxCommand.org project at http://linuxcommand.org. Release History Version Date Description 19.01A January 28, 2019 Fifth Internet Edition (Corrected TOC) 19.01 January 17, 2019 Fifth Internet Edition. 17.10 October 19, 2017 Fourth Internet Edition. 16.07 July 28, 2016 Third Internet Edition. 13.07 July 6, 2013 Second Internet Edition. 09.12 December 14, 2009 First Internet Edition. Table of Contents Introduction....................................................................................................xvi Why Use the Command Line?......................................................................................xvi
    [Show full text]
  • Student Number: Surname: Given Name
    Computer Science 2211a Midterm Examination Sample Solutions 9 November 20XX 1 hour 40 minutes Student Number: Surname: Given name: Instructions/Notes: The examination has 35 questions on 9 pages, and a total of 110 marks. Put all answers on the question paper. This is a closed book exam. NO ELECTRONIC DEVICES OF ANY KIND ARE ALLOWED. 1. [4 marks] Which of the following Unix commands/utilities are filters? Correct answers are in blue. mkdir cd nl passwd grep cat chmod scriptfix mv 2. [1 mark] The Unix command echo HOME will print the contents of the environment variable whose name is HOME. True False 3. [1 mark] In C, the null character is another name for the null pointer. True False 4. [3 marks] The protection code for the file abc.dat is currently –rwxr--r-- . The command chmod a=x abc.dat is equivalent to the command: a. chmod 755 abc.dat b. chmod 711 abc.dat c. chmod 155 abc.dat d. chmod 111 abc.dat e. none of the above 5. [3 marks] The protection code for the file abc.dat is currently –rwxr--r-- . The command chmod ug+w abc.dat is equivalent to the command: a. chmod 766 abc.dat b. chmod 764 abc.dat c. chmod 754 abc.dat d. chmod 222 abc.dat e. none of the above 2 6. [3 marks] The protection code for def.dat is currently dr-xr--r-- , and the protection code for def.dat/ghi.dat is currently -r-xr--r-- . Give one or more chmod commands that will set the protections properly so that the owner of the two files will be able to delete ghi.dat using the command rm def.dat/ghi.dat chmod u+w def.dat or chmod –r u+w def.dat 7.
    [Show full text]
  • Unix Security Overview: 1
    CIS/CSE 643: Computer Security (Syracuse University) Unix Security Overview: 1 Unix Security Overview 1 User and Group • Users – root: super user (uid = 0) – daemon: handle networks. – nobody: owns no files, used as a default user for unprivileged operations. ∗ Web browser can run with this mode. – User needs to log in with a password. The encrypted password is stored in /etc/shadow. – User information is stored in /etc/passwd, the place that was used to store passwords (not anymore). The following is an example of an entry in this file. john:x:30000:40000:John Doe:/home/john:/usr/local/bin/tcsh • Groups – Sometimes, it is more convenient if we can assign permissions to a group of users, i.e. we would like to assign permission based on groups. – A user has a primary group (listed in /etc/passwd), and this is the one associated to the files the user created. – Any user can be a member of multiple groups. – Group member information is stored in /etc/group % groups uid (display the groups that uid belongs to) – For systems that use NIS (Network Information Service), originally called Yellow Page (YP), we can get the group information using the command ypcat. % ypcat group (can display all the groups and their members) 2 File Permissions • File Permissions – The meaning of the permission bits in Unix. ∗ Owner (u), Group (g), and Others (o). ∗ Readable (r), Writable (w), and Executable (x). ∗ Example: -rwxrwxrwx (777) • Permissions on Directories: – r: the directory can be listed. – w: can create/delete a file or a directory within the directory.
    [Show full text]
  • File Security Lock Down Your Data
    File Security Lock Down Your Data Brian Reames January 22, 2012 Table of Contents 1.0 Basic Linux Permissions...............................................................................................................4 1.1 Determining Permissions……………………………………………………………………..................... 5 1.2 File Permissions vs. Directory Permissions………………………………………………….............. 6 1.3 Changing Permissions………………………………………………………………………….................... 7 1.3.1 Symbolic Method…………………………………………………………………….................... 8 1.3.2 Octal Method………………………………………………………………………..................... 10 1.3.3 Changing Permissions Graphically……………………………………………….............. 12 1.4 Examples of Unintentional Access…………………………………………………………................. 13 2.0 Setting Default Permissions………………………………………………………………………...................... 15 2.1 Common umask Settings……………………………………………………………………....................17 3.0 Advanced Linux Permissions……………………………………………………………………….................... 18 3.1 Special Permission: setuid………………………………………………………………….....................19 3.1.1 Setting the setuid Permission……………………………………………………................ 20 3.1.2 Caution Regarding setuid………………………………………………………….................22 3.2 Special Permission setgid……………………………………………………………………................... 23 3.2.1 setgid on a File……………………………………………………………………...................... 24 3.2.2 setgid on a Directory……………………………………………………………….................. 25 3.2.3 Caution Regarding setgid…………………………………………………………................. 28 3.3 Special Permission: sticky bit………………………………………………………………..................
    [Show full text]
  • Pingdirectory Administration Guide Version
    Release 7.3.0.3 Server Administration Guide PingDirectory | Contents | ii Contents PingDirectory™ Product Documentation................................................ 20 Overview of the Server............................................................................. 20 Server Features.................................................................................................................................20 Administration Framework.................................................................................................................21 Server Tools Location....................................................................................................................... 22 Preparing Your Environment....................................................................22 Before You Begin.............................................................................................................................. 22 System requirements..............................................................................................................22 Installing Java......................................................................................................................... 23 Preparing the Operating System (Linux).......................................................................................... 24 Configuring the File Descriptor Limits.................................................................................... 24 File System Tuning.................................................................................................................25
    [Show full text]
  • Install and Run External Command Line Softwares
    job monitor and control top: similar to windows task manager (space to refresh, q to exit) w: who is there ps: all running processes, PID, status, type ps -ef | grep yyin bg: move current process to background fg: move current process to foreground jobs: list running and suspended processes kill: kill processes kill pid (could find out using top or ps) 1 sort, cut, uniq, join, paste, sed, grep, awk, wc, diff, comm, cat All types of bioinformatics sequence analyses are essentially text processing. Unix Shell has the above commands that are very useful for processing texts and also allows the output from one command to be passed to another command as input using pipe (“|”). less cosmicRaw.txt | cut -f2,3,4,5,8,13 | awk '$5==22' | cut -f1 | sort -u | wc This makes the processing of files using Shell very convenient and very powerful: you do not need to write output to intermediate files or load all data into the memory. For example, combining different Unix commands for text processing is like passing an item through a manufacturing pipeline when you only care about the final product 2 Hands on example 1: cosmic mutation data - Go to UCSC genome browser website: http://genome.ucsc.edu/ - On the left, find the Downloads link - Click on Human - Click on Annotation database - Ctrl+f and then search “cosmic” - On “cosmic.txt.gz” right-click -> copy link address - Go to the terminal and wget the above link (middle click or Shift+Insert to paste what you copied) - Similarly, download the “cosmicRaw.txt.gz” file - Under your home, create a folder
    [Show full text]
  • The AWK Programming Language
    The Programming ~" ·. Language PolyAWK- The Toolbox Language· Auru:o V. AHo BRIAN W.I<ERNIGHAN PETER J. WEINBERGER TheAWK4 Programming~ Language TheAWI(. Programming~ Language ALFRED V. AHo BRIAN w. KERNIGHAN PETER J. WEINBERGER AT& T Bell Laboratories Murray Hill, New Jersey A ADDISON-WESLEY•• PUBLISHING COMPANY Reading, Massachusetts • Menlo Park, California • New York Don Mills, Ontario • Wokingham, England • Amsterdam • Bonn Sydney • Singapore • Tokyo • Madrid • Bogota Santiago • San Juan This book is in the Addison-Wesley Series in Computer Science Michael A. Harrison Consulting Editor Library of Congress Cataloging-in-Publication Data Aho, Alfred V. The AWK programming language. Includes index. I. AWK (Computer program language) I. Kernighan, Brian W. II. Weinberger, Peter J. III. Title. QA76.73.A95A35 1988 005.13'3 87-17566 ISBN 0-201-07981-X This book was typeset in Times Roman and Courier by the authors, using an Autologic APS-5 phototypesetter and a DEC VAX 8550 running the 9th Edition of the UNIX~ operating system. -~- ATs.T Copyright c 1988 by Bell Telephone Laboratories, Incorporated. All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form or by any means, electronic, mechanical, photocopy­ ing, recording, or otherwise, without the prior written permission of the publisher. Printed in the United States of America. Published simultaneously in Canada. UNIX is a registered trademark of AT&T. DEFGHIJ-AL-898 PREFACE Computer users spend a lot of time doing simple, mechanical data manipula­ tion - changing the format of data, checking its validity, finding items with some property, adding up numbers, printing reports, and the like.
    [Show full text]