FEEG Applied Programming 7 - Shell scripts and Makefiles
|
|
- Oswin Robinson
- 7 years ago
- Views:
Transcription
1 FEEG Applied Programming 7 - Shell scripts and Makefiles Sam Sinayoko / 44
2 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 2 / 44
3 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 3 / 44
4 Learning outcomes Give three reasons for writing shell scripts Learn the basics of shell scripts: Make files defining variables passing arguments Give three reasons for writing make files Learn the basics: Using make to build a program from source Using make to (re)generate a series of files 4 / 44
5 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 5 / 44
6 Introduction Motivation for shell scripts Automate simple tasks: creating/copying/moving files or directories simple data processing running a series of programs successively Scalable: run the same commands on a 1000 files Makes it easy to pass arguments to commands Examples: script for downloading lecture notes from feeg6002 website into a specific directory script for downloading a C program from feeg6002 course into a specific directory and compiling it with gcc 6 / 44
7 Introduction Motivation for make files Easily build / re-build a set of files Particularly useful to build programs in C or other compiled language Reproducible papers: makes it easy to update the paper and its figures after changing something (e.g. one data file, or one program) Captures dependencies between files so only the necessary files are re-built when some of the source files are changed (unlike a shell script which runs all commands) Independent commands can be run in parallel Other similar programs exist (scons, ant, cmake), but: make is already installed on any Linux/OS X machine philosophy is similar Example: feeg6002 website and lecture notes, most open source programs (e.g. emacs, vim). 7 / 44
8 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 8 / 44
9 Elementary shell scripts Simply put the list of successive commands you want to run into a file and run with the "bash" shell command. cmd1 cmd2 cmd3... It is common to append the suffix ".sh" to make it clear the file is a shell script. 9 / 44
10 Elementary shell scripts Example: downloading lecture notes into some folder On Linux/OS X, create file =feeg6002pdf.sh= 1 : mkdir -p /tmp/feeg6002/applied_programming/ wget feeg6002_applied_programming01.pdf mv feeg6002_applied_programming01.pdf \ /tmp/feeg6002/applied_programming/ Run the script (see Appendix A for an alternative): bash feeg6002pdf.sh ls /tmp/feeg6002/applied_programming feeg6002_applied_programming01.pdf 1 The "\" is for splitting long lines to fit the command to the screen. 10 / 44
11 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 11 / 44
12 Shell script variables Basic syntax No need to declare variable type as in C. By default everything is a string Variables are defined and used like this NAME=World echo Hello $NAME Hello World Notes: no space around equal sign. Use dollar sign $ to expand variable name. 12 / 44
13 Shell script variables Variable names in strings Variable in double quoted "strings" are expanded Variable in single quoted strings are not expanded. NAME=world echo "Hello double quoted $NAME" echo Hello single quoted $NAME (Oops) Hello double quoted world Hello single quoted $NAME (Oops) 13 / 44
14 Shell scripts variables Protecting variable names with ${} Use curly brackets to separate variable name from the rest FILE="image" echo $FILE01.png "(broken)" echo ${FILE}01.png "(works)".png (broken) image01.png (works) Note: there is no variable FILE01 so it defaults to the empty string, the shell doesn t throw an error. 14 / 44
15 Shell script Improved script feeg sh FOLDER=/tmp/feeg6002/applied_programming/ N=01 # lecture number filename=feeg6002_applied_programming$n.pdf mkdir -p $FOLDER wget mv $filename $FOLDER 15 / 44
16 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 16 / 44
17 Command line arguments Command line arguments It is very easy to define command line arguments The following variables are available automatically: $0 command name $1 argument 1 $2 argument $9 argument 9 $@ all arguments $# number of arguments 17 / 44
18 Command line arguments Command line arguments: example (1/2) Define file "arg-test.sh": echo "command: $0" echo "arg 1: $1" echo "arg 2: $2" echo "arg 3: $3" echo "all args: echo "number of args: $#" 18 / 44
19 Command line arguments Command line arguments: example (2/2) Test file "arg-test.sh": bash arg-test.sh I love Southampton command: arg-test.sh arg 1: I arg 2: love arg 3: Southampton all args: I love Southampton number of args: 3 19 / 44
20 Shell script Improved script feeg sh FOLDER=/tmp/feeg6002/applied_programming/ N=$(printf "%02d" $1) # lecture number filename=feeg6002_applied_programming$n.pdf mkdir -p $FOLDER wget mv $filename $FOLDER Usage: bash feeg6002pdf-3.sh 1 bash feeg6002pdf-3.sh 2 ls /tmp/feeg6002/applied_programming feeg6002_applied_programming01.pdf feeg6002_applied_programming02.pdf 20 / 44
21 Self study Exercise Write a shell script getcode.sh that: 1. takes any C file cmd.c (e.g. hello.c) from Professor Fangohr s FEEG6002 lecture notes as an argument 2. downloads the file from 3. moves it to an existing directory of your choice 4. (optional) compiles the source file with gcc and creates executable cmd Example usage bash getcode.sh hello.c cd code # or wherever getcode.sh sends the files./hello 21 / 44
22 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 22 / 44
23 Make: introduction The creation of a series of files via a list of commands can be described through: a flow chart: the intuitive way. a dependency graph: the more powerful way used by the make program. Flow charts An intuitive way to describe a build is through a flow chart. The program flows from the source to the target. Flow chart 1: "Hello world" C program. gcc Source: hello.c Target: hello 23 / 44
24 Make: introduction Flow chart 2: plotting data (from lab 3, tabulatesin.c gcc tabulatesin figure.png plotfile.py data.txt redirect STDOUT 24 / 44
25 Make: introduction Dependency graph In a Makefile, one defines a dependency graph instead. Dependency graph example for hello depends on Target: hello Source: hello.c Command: gcc 25 / 44
26 Make: introduction Dependency graph Dependency graph example for lab 3 tabulatesin.c depends on tabulatesin figure.png depends on data.txt depends on depends on plofile.py 26 / 44
27 Make: defining the Makefile and running make The make looks for a file called Makefile in the working directory. Makefile syntax Makefiles take the form target: source [tab] command The file "target" depends on file "source" The program "command" is used to generate file "target" The tab is necessary! Running make In a terminal, running make target builds target by executing command. 27 / 44
28 Make: hello example Dependency graph Target: hello depends on Source: hello.c Command: gcc Makefile Save the following Makefile to the directory containing hello.c. hello: hello.c gcc -Wall -ansi -pedantic -o hello hello.c 28 / 44
29 Make: hello example Building hello make hello gcc -Wall -ansi -pedantic -o hello hello.c Note: make prints the commands it runs to the screen. If we run make again, we get make: hello is up to date. 29 / 44
30 Make: Makefiles with multiple sources and targets Makefiles can declare multiple targets and sources: target1: source1 source2 command1a command1b target2: target1 command2 Important: the targets can be defined in any order! Make builds the dependency graph from the Makefile and only builds the necessary files. Example Building "target2" with "make target2" will automatically build "target1" if it is missing it is out of date ("source1" or "source2" have changed). 30 / 44
31 Make: lab3 example Dependency graph tabulatesin.c figure.png depends on depends on tabulatesin data.txt depends on depends on plofile.py 31 / 44
32 Make: lab3 example Makefile figure.png: plotfile.py data.txt python plotfile.py data.txt data.txt: tabulatesin./tabulatesin > data.txt tabulatesin: tabulatesin.c gcc -Wall -ansi -pedantic -o tabulatesin tabulatesin.c clean: rm data.txt tabulatesin plotfile.py plotfile.py: wget tools/plotfile2.py mv plotfile2.py plotfile.py 32 / 44
33 Make: lab3 example Build figure.png Copy plotfile.py and tabulatesin.c to the working directory. Modify plotfile.py so that it saves the figuret make clean make figure.png rm data.txt tabulatesin plotfile.py wget gcc -Wall -ansi -pedantic -o tabulatesin tabulatesin.c./tabulatesin > data.txt python plotfile.py data.txt Data in data.txt has 10 rows and 2 columns 33 / 44
34 Make: lab3 example Figure 34 / 44
35 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 35 / 44
36 Conclusions Use shell scripts to automate repetitive tasks Use make and Makefiles for to manage complexity only runs the steps that are necessary useful to build complex programs useful for reproducible science 36 / 44
37 References Bash programming HOW-TO: Blog post on make for scientists: Reproducible papers with make: GNU Make manual: O Reilly (open) book on Make: 37 / 44
38 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 38 / 44
39 Appendix A: running scripts with a shebang To having to call the appropriate program (bash, python, zsh etc) everytime, one can include a shebang as the first line of the script. For bash, the shebang is of the form: #!/usr/bin/env bash One can also provide the path to the executable #!/home/user/ss1234/apps/anaconda/bin/python For security reasons, you must also run the following command to make the script executable: chmod u+x feeg6002pdf.sh The script can then by run with./feeg6002pdf.sh The./ in not needed if the script is in one of the folders listed in the PATH environmental variable (display it with echo $PATH). 39 / 44
40 Appendix B: storing command output into a variable Storing command output into a variable with $() You can store the output of a command in a variable. For example the following command prints the value of π. python -c "import math; print math.pi" You can assign the output to a variable with $(): PI=$(python -c "import math; print math.pi") echo $PI / 44
41 Appendix C: Makefile for simple C program This Makefile can be used to compile a C program called myprogram.c into an executable myprogram, with the appropriate flags and compiler. Change the value of TARGET to customize the file to your needs. TARGET = myprogram # name of program CC = gcc # compiler CFLAGS = -g -Wall # flags all: $(TARGET) $(TARGET): $(TARGET).c $(CC) $(CFLAGS) -o $(TARGET) $(TARGET).c clean: $(RM) $(TARGET) This complex Makefile compiles all.c files in a directory. 41 / 44
42 Outline Learning outcomes Introduction Elementary Shell scripts Variables Command line arguments Make files Conclusions Appendix Questionmark Perception Exam 42 / 44
43 Questionmark Perception Exam Watch isolution s introductory video General information about Questionmark Perception 43 / 44
44 How to revise See Test section on FEEG6002 website. Topics that will not be examined Cython, Weave, Ctypes, IPython, SymPy, Numerical Methods. C part Review your own C programs from each lab. Make sure you remember the syntax. You should be able to read/write/debug short programs. Applied Programming Review each lecture / tutorial Focus on the learning outcomes: these are the things I expect you to be able to do Are you able to predict the output of each code block? Would you be able to write such code blocks yourself? 44 / 44
CS2720 Practical Software Development
Page 1 Rex Forsyth CS2720 Practical Software Development CS2720 Practical Software Development Scripting Tutorial Srping 2011 Instructor: Rex Forsyth Office: C-558 E-mail: forsyth@cs.uleth.ca Tel: 329-2496
More informationLab 1: Introduction to C, ASCII ART and the Linux Command Line Environment
.i.-' `-. i..' `/ \' _`.,-../ o o \.' ` ( / \ ) \\\ (_.'.'"`.`._) /// \\`._(..: :..)_.'// \`. \.:-:. /.'/ `-i-->..
More informationA Crash Course on UNIX
A Crash Course on UNIX UNIX is an "operating system". Interface between user and data stored on computer. A Windows-style interface is not required. Many flavors of UNIX (and windows interfaces). Solaris,
More informationCPSC 226 Lab Nine Fall 2015
CPSC 226 Lab Nine Fall 2015 Directions. Our overall lab goal is to learn how to use BBB/Debian as a typical Linux/ARM embedded environment, program in a traditional Linux C programming environment, and
More informationCommand Line - Part 1
Command Line - Part 1 STAT 133 Gaston Sanchez Department of Statistics, UC Berkeley gastonsanchez.com github.com/gastonstat Course web: gastonsanchez.com/teaching/stat133 GUIs 2 Graphical User Interfaces
More informationTNM093 Practical Data Visualization and Virtual Reality Laboratory Platform
October 6, 2015 1 Introduction The laboratory exercises in this course are to be conducted in an environment that might not be familiar to many of you. It is based on open source software. We use an open
More informationExtreme computing lab exercises Session one
Extreme computing lab exercises Session one Michail Basios (m.basios@sms.ed.ac.uk) Stratis Viglas (sviglas@inf.ed.ac.uk) 1 Getting started First you need to access the machine where you will be doing all
More informationIntroduction to Python
Introduction to Python Sophia Bethany Coban Problem Solving By Computer March 26, 2014 Introduction to Python Python is a general-purpose, high-level programming language. It offers readable codes, and
More informationCommand Line Crash Course For Unix
Command Line Crash Course For Unix Controlling Your Computer From The Terminal Zed A. Shaw December 2011 Introduction How To Use This Course You cannot learn to do this from videos alone. You can learn
More informationCS2043 - Unix Tools & Scripting Lecture 9 Shell Scripting
CS2043 - Unix Tools & Scripting Lecture 9 Shell Scripting Spring 2015 1 February 9, 2015 1 based on slides by Hussam Abu-Libdeh, Bruno Abrahao and David Slater over the years Announcements Coursework adjustments
More informationUnix Shell Scripts. Contents. 1 Introduction. Norman Matloff. July 30, 2008. 1 Introduction 1. 2 Invoking Shell Scripts 2
Unix Shell Scripts Norman Matloff July 30, 2008 Contents 1 Introduction 1 2 Invoking Shell Scripts 2 2.1 Direct Interpretation....................................... 2 2.2 Indirect Interpretation......................................
More informationIntroduction to Linux and Cluster Basics for the CCR General Computing Cluster
Introduction to Linux and Cluster Basics for the CCR General Computing Cluster Cynthia Cornelius Center for Computational Research University at Buffalo, SUNY 701 Ellicott St Buffalo, NY 14203 Phone: 716-881-8959
More informationLinux command line. An introduction to the Linux command line for genomics. Susan Fairley
Linux command line An introduction to the Linux command line for genomics Susan Fairley Aims Introduce the command line Provide an awareness of basic functionality Illustrate with some examples Provide
More informationCS 103 Lab Linux and Virtual Machines
1 Introduction In this lab you will login to your Linux VM and write your first C/C++ program, compile it, and then execute it. 2 What you will learn In this lab you will learn the basic commands and navigation
More informationTutorial 0A Programming on the command line
Tutorial 0A Programming on the command line Operating systems User Software Program 1 Program 2 Program n Operating System Hardware CPU Memory Disk Screen Keyboard Mouse 2 Operating systems Microsoft Apple
More informationUnix Sampler. PEOPLE whoami id who
Unix Sampler PEOPLE whoami id who finger username hostname grep pattern /etc/passwd Learn about yourself. See who is logged on Find out about the person who has an account called username on this host
More informationBuilding Programs with Make. What does it mean to Build a Program?
Building Programs with Make http://www.oit.duke.edu/scsc/ http://wiki.duke.edu/display/scsc scsc@duke.edu John Pormann, Ph.D. jbp1@duke.edu What does it mean to Build a Program? Often, a single executable
More informationNo Frills Command Line Magento
No Frills Command Line Magento Alan Storm 2013 Pulse Storm LLC Contents Introduction............................................ 1 What This Book Is........................................ 1 About the
More informationBuilding Software Systems. Multi-module C Programs. Example Multi-module C Program. Example Multi-module C Program
Building Software Systems Multi-module C Programs Software systems need to be built / re-built during the development phase if distributed in source code form (change,compile,test,repeat) (assists portability)
More informationCloud Computing. Chapter 8. 8.1 Hadoop
Chapter 8 Cloud Computing In cloud computing, the idea is that a large corporation that has many computers could sell time on them, for example to make profitable use of excess capacity. The typical customer
More informationUnix the Bare Minimum
Unix the Bare Minimum Norman Matloff September 27, 2005 c 2001-2005, N.S. Matloff Contents 1 Purpose 2 2 Shells 2 3 Files and Directories 4 3.1 Creating Directories.......................................
More informationUniversity of Toronto
1 University of Toronto APS 105 Computer Fundamentals A Tutorial about UNIX Basics Fall 2011 I. INTRODUCTION This document serves as your introduction to the computers we will be using in this course.
More informationC Programming Review & Productivity Tools
Review & Productivity Tools Giovanni Agosta Piattaforme Software per la Rete Modulo 2 Outline Preliminaries 1 Preliminaries 2 Function Pointers Variadic Functions 3 Build Automation Code Versioning 4 Preliminaries
More informationAn Introduction to Using the Command Line Interface (CLI) to Work with Files and Directories
An Introduction to Using the Command Line Interface (CLI) to Work with Files and Directories Mac OS by bertram lyons senior consultant avpreserve AVPreserve Media Archiving & Data Management Consultants
More informationExtreme computing lab exercises Session one
Extreme computing lab exercises Session one Miles Osborne (original: Sasa Petrovic) October 23, 2012 1 Getting started First you need to access the machine where you will be doing all the work. Do this
More informationRunning your first Linux Program
Running your first Linux Program This document describes how edit, compile, link, and run your first linux program using: - Gnome a nice graphical user interface desktop that runs on top of X- Windows
More informationTutorial Guide to the IS Unix Service
Tutorial Guide to the IS Unix Service The aim of this guide is to help people to start using the facilities available on the Unix and Linux servers managed by Information Services. It refers in particular
More informationUSEFUL UNIX COMMANDS
cancel cat file USEFUL UNIX COMMANDS cancel print requested with lp Display the file cat file1 file2 > files Combine file1 and file2 into files cat file1 >> file2 chgrp [options] newgroup files Append
More informationIntroduction. Created by Richard Bell 10/29/2014
Introduction GNU Radio is open source software that provides built in modules for standard tasks of a wireless communications system. Within the GNU Radio framework is gnuradio-companion, which is a GUI
More informationCS 2112 Lab: Version Control
29 September 1 October, 2014 Version Control What is Version Control? You re emailing your project back and forth with your partner. An hour before the deadline, you and your partner both find different
More informationCP Lab 2: Writing programs for simple arithmetic problems
Computer Programming (CP) Lab 2, 2015/16 1 CP Lab 2: Writing programs for simple arithmetic problems Instructions The purpose of this Lab is to guide you through a series of simple programming problems,
More informationSetting up PostgreSQL
Setting up PostgreSQL 1 Introduction to PostgreSQL PostgreSQL is an object-relational database management system based on POSTGRES, which was developed at the University of California at Berkeley. PostgreSQL
More informationBasic C Shell. helpdesk@stat.rice.edu. 11th August 2003
Basic C Shell helpdesk@stat.rice.edu 11th August 2003 This is a very brief guide to how to use cshell to speed up your use of Unix commands. Googling C Shell Tutorial can lead you to more detailed information.
More informationOpening a Command Shell
Opening a Command Shell Win Cmd Line 1 In WinXP, go to the Programs Menu, select Accessories and then Command Prompt. In Win7, go to the All Programs, select Accessories and then Command Prompt. Note you
More informationCMPT 373 Software Development Methods. Building Software. Nick Sumner wsumner@sfu.ca Some materials from Shlomi Fish & Kitware
CMPT 373 Software Development Methods Building Software Nick Sumner wsumner@sfu.ca Some materials from Shlomi Fish & Kitware What does it mean to build software? How many of you know how to build software?
More informationStep By Step Guide for Starting "Hello, World!" on OpenWRT
Step By Step Guide for Starting "Hello, World!" on OpenWRT Installation. All actions of this step should be performed by a non-root user. Directories with spaces in their full path are not allowed. 1.
More informationIntroduction to analyzing big data using Amazon Web Services
Introduction to analyzing big data using Amazon Web Services This tutorial accompanies the BARC seminar given at Whitehead on January 31, 2013. It contains instructions for: 1. Getting started with Amazon
More informationShell Scripts (1) For example: #!/bin/sh If they do not, the user's current shell will be used. Any Unix command can go in a shell script
Shell Programming Shell Scripts (1) Basically, a shell script is a text file with Unix commands in it. Shell scripts usually begin with a #! and a shell name For example: #!/bin/sh If they do not, the
More informationLecture 4: Writing shell scripts
Handout 5 06/03/03 1 Your rst shell script Lecture 4: Writing shell scripts Shell scripts are nothing other than les that contain shell commands that are run when you type the le at the command line. That
More informationCS 253: Intro to Systems Programming
CS 253: Intro to Systems Programming Spring 2014 Amit Jain, Shane Panter, Marissa Schmidt Department of Computer Science College of Engineering Boise State University Logistics Instructor: Amit Jain http://cs.boisestate.edu/~amit
More informationComputational Mathematics with Python
Boolean Arrays Classes Computational Mathematics with Python Basics Olivier Verdier and Claus Führer 2009-03-24 Olivier Verdier and Claus Führer Computational Mathematics with Python 2009-03-24 1 / 40
More informationSystems Programming & Scripting
Systems Programming & Scripting Lecture 14 - Shell Scripting: Control Structures, Functions Syst Prog & Scripting - Heriot Watt University 1 Control Structures Shell scripting supports creating more complex
More informationIntroduction to Shell Programming
Introduction to Shell Programming what is shell programming? about cygwin review of basic UNIX TM pipelines of commands about shell scripts some new commands variables parameters and shift command substitution
More informationFEEG6002 - Applied Programming 3 - Version Control and Git II
FEEG6002 - Applied Programming 3 - Version Control and Git II Sam Sinayoko 2015-10-16 1 / 26 Outline Learning outcomes Working with a single repository (review) Working with multiple versions of a repository
More informationNotepad++ The COMPSCI 101 Text Editor for Windows. What is a text editor? Install Python 3
Notepad++ The COMPSCI 101 Text Editor for Windows The text editor that we will be using in the Computer Science labs for creating our Python programs is called Notepad++ and http://notepad-plus-plus.org
More informationAN INTRODUCTION TO UNIX
AN INTRODUCTION TO UNIX Paul Johnson School of Mathematics September 24, 2010 OUTLINE 1 SHELL SCRIPTS Shells 2 COMMAND LINE Command Line Input/Output 3 JOBS Processes Job Control 4 NETWORKING Working From
More informationCreating a Java application using Perfect Developer and the Java Develo...
1 of 10 15/02/2010 17:41 Creating a Java application using Perfect Developer and the Java Development Kit Introduction Perfect Developer has the facility to execute pre- and post-build steps whenever the
More informationHands-On UNIX Exercise:
Hands-On UNIX Exercise: This exercise takes you around some of the features of the shell. Even if you don't need to use them all straight away, it's very useful to be aware of them and to know how to deal
More informationCode::Block manual. for CS101x course. Department of Computer Science and Engineering Indian Institute of Technology - Bombay Mumbai - 400076.
Code::Block manual for CS101x course Department of Computer Science and Engineering Indian Institute of Technology - Bombay Mumbai - 400076. April 9, 2014 Contents 1 Introduction 1 1.1 Code::Blocks...........................................
More informationcloud-kepler Documentation
cloud-kepler Documentation Release 1.2 Scott Fleming, Andrea Zonca, Jack Flowers, Peter McCullough, El July 31, 2014 Contents 1 System configuration 3 1.1 Python and Virtualenv setup.......................................
More informationMOVES Batch Mode: Setting up and running groups of related MOVES run specifications. EPA Office of Transportation and Air Quality 11/3/2010
MOVES Batch Mode: Setting up and running groups of related MOVES run specifications EPA Office of Transportation and Air Quality 11/3/2010 Webinar Logistics Please use question box to send any questions
More informationMagento Search Extension TECHNICAL DOCUMENTATION
CHAPTER 1... 3 1. INSTALLING PREREQUISITES AND THE MODULE (APACHE SOLR)... 3 1.1 Installation of the search server... 3 1.2 Configure the search server for usage with the search module... 7 Deploy the
More informationIntroduction to CloudScript
Introduction to CloudScript A NephoScale Whitepaper Authors: Nick Peterson, Alan Meadows Date: 2012-07-06 CloudScript is a build language for the cloud. It is a simple Domain Specific Language (DSL) that
More informationFEEG6002 - Applied Programming 6 - Working Remotely on Linux Server
FEEG6002 - Applied Programming 6 - Working Remotely on Linux Server Sam Sinayoko 2015-11-06 1 / 25 Outline Learning Outcomes Introduction Connecting to Linux server Transfering files to Linux server Text
More informationAn Introduction to the Linux Command Shell For Beginners
An Introduction to the Linux Command Shell For Beginners Presented by: Victor Gedris In Co-Operation With: The Ottawa Canada Linux Users Group and ExitCertified Copyright and Redistribution This manual
More informationMakefiles and ROOT. Sean Brisbane 12/12/11
Makefiles and ROOT Sean Brisbane 12/12/11 Introduction and purpose By the end of today you should know: The basics of the g++ compiler; How to write Makefiles for medium-sized projects; How to build a
More informationQUICK START BASIC LINUX AND G++ COMMANDS. Prepared By: Pn. Azura Bt Ishak
QUICK START BASIC LINUX AND G++ COMMANDS Prepared By: Pn. Azura Bt Ishak FTSM UKM BANGI 2009 Content 1.0 About UBUNTU 1 2.0 Terminal 1 3.0 Basic Linux Commands 3 4.0 G++ Commands 23 1.0 ABOUT UBUNTU Ubuntu
More information1001ICT Introduction To Programming Lecture Notes
1001ICT Introduction To Programming Lecture Notes School of Information and Communication Technology Griffith University Semester 2, 2015 1 3 A First MaSH Program In this section we will describe a very
More informationSteps for running C-program
Steps for running C-program for AVR microcontroller on Linux Step:1 Installation of required packages We will first install all the required packages. This includes 1. binutils - Tools like the assembler,
More informationCommand-Line Operations : The Shell. Don't fear the command line...
Command-Line Operations : The Shell Don't fear the command line... Shell Graphical User Interface (GUI) Graphical User Interface : displays to interact with the computer - Open and manipulate files and
More informationCode::Blocks Student Manual
Code::Blocks Student Manual Lawrence Goetz, Network Administrator Yedidyah Langsam, Professor and Theodore Raphan, Distinguished Professor Dept. of Computer and Information Science Brooklyn College of
More informationQ N X S O F T W A R E D E V E L O P M E N T P L A T F O R M v 6. 4. 10 Steps to Developing a QNX Program Quickstart Guide
Q N X S O F T W A R E D E V E L O P M E N T P L A T F O R M v 6. 4 10 Steps to Developing a QNX Program Quickstart Guide 2008, QNX Software Systems GmbH & Co. KG. A Harman International Company. All rights
More informationComputational Mathematics with Python
Numerical Analysis, Lund University, 2011 1 Computational Mathematics with Python Chapter 1: Basics Numerical Analysis, Lund University Claus Führer, Jan Erik Solem, Olivier Verdier, Tony Stillfjord Spring
More informationComputational Mathematics with Python
Computational Mathematics with Python Basics Claus Führer, Jan Erik Solem, Olivier Verdier Spring 2010 Claus Führer, Jan Erik Solem, Olivier Verdier Computational Mathematics with Python Spring 2010 1
More informationInstalling C++ compiler for CSc212 Data Structures
for CSc212 Data Structures WKhoo@gc.cuny.edu Spring 2010 1 2 Testing Mac 3 Why are we not using Visual Studio, an Integrated Development (IDE)? Here s several reasons: Visual Studio is good for LARGE project.
More informationCTIS486 Midterm I 20/11/2012 - Akgül
Surname, Name: Section: Student No: Closed Book, closed note exam. You are required to write down commands with necessary arguments and options; and make sure that they work. Your script and output should
More informationCS 1133, LAB 2: FUNCTIONS AND TESTING http://www.cs.cornell.edu/courses/cs1133/2015fa/labs/lab02.pdf
CS 1133, LAB 2: FUNCTIONS AND TESTING http://www.cs.cornell.edu/courses/cs1133/2015fa/labs/lab02.pdf First Name: Last Name: NetID: The purpose of this lab is to help you to better understand functions:
More informationInstallation Guide for AmiRNA and WMD3 Release 3.1
Installation Guide for AmiRNA and WMD3 Release 3.1 by Joffrey Fitz and Stephan Ossowski 1 Introduction This document describes the installation process for WMD3/AmiRNA. WMD3 (Web Micro RNA Designer version
More informationBASH Scripting. A bash script may consist of nothing but a series of command lines, e.g. The following helloworld.sh script simply does an echo.
BASH Scripting bash is great for simple scripts that automate things you would otherwise by typing on the command line. Your command line skills will carry over to bash scripting and vice versa. bash comments
More informationLab 1 Beginning C Program
Lab 1 Beginning C Program Overview This lab covers the basics of compiling a basic C application program from a command line. Basic functions including printf() and scanf() are used. Simple command line
More informationHadoop Tutorial GridKa School 2011
Hadoop Tutorial GridKa School 2011 Ahmad Hammad, Ariel García Karlsruhe Institute of Technology September 7, 2011 Abstract This tutorial intends to guide you through the basics of Data Intensive Computing
More informationLecture 22 The Shell and Shell Scripting
Lecture 22 The Shell and Shell Scripting In this lecture The UNIX shell Simple Shell Scripts Shell variables File System s, IO s, IO redirection Command Line Arguments Evaluating Expr in Shell Predicates,
More informationGeBro-BACKUP. Die Online-Datensicherung. Manual Pro Backup Client on a NAS
GeBro-BACKUP Die Online-Datensicherung. Manual Pro Backup Client on a NAS Created and tested on a QNAP TS-559 Pro Firmware 4.0.2 Intel x86 Architecture Default hardware configuration OBM v6.15.0.0 Last
More informationUsing Parallel Computing to Run Multiple Jobs
Beowulf Training Using Parallel Computing to Run Multiple Jobs Jeff Linderoth August 5, 2003 August 5, 2003 Beowulf Training Running Multiple Jobs Slide 1 Outline Introduction to Scheduling Software The
More informationBeginners Shell Scripting for Batch Jobs
Beginners Shell Scripting for Batch Jobs Evan Bollig and Geoffrey Womeldorff Before we begin... Everyone please visit this page for example scripts and grab a crib sheet from the front http://www.scs.fsu.edu/~bollig/techseries
More informationUNIX, Shell Scripting and Perl Introduction
UNIX, Shell Scripting and Perl Introduction Bart Zeydel 2003 Some useful commands grep searches files for a string. Useful for looking for errors in CAD tool output files. Usage: grep error * (looks for
More informationAppendix K Introduction to Microsoft Visual C++ 6.0
Appendix K Introduction to Microsoft Visual C++ 6.0 This appendix serves as a quick reference for performing the following operations using the Microsoft Visual C++ integrated development environment (IDE):
More informationAn Introduction to Using the Command Line Interface (CLI) to Work with Files and Directories
An Introduction to Using the Command Line Interface (CLI) to Work with Files and Directories Windows by bertram lyons senior consultant avpreserve AVPreserve Media Archiving & Data Management Consultants
More informationHadoop Shell Commands
Table of contents 1 DFShell... 3 2 cat...3 3 chgrp...3 4 chmod...3 5 chown...4 6 copyfromlocal... 4 7 copytolocal... 4 8 cp...4 9 du...4 10 dus... 5 11 expunge... 5 12 get... 5 13 getmerge... 5 14 ls...
More informationYocto Project Eclipse plug-in and Developer Tools Hands-on Lab
Yocto Project Eclipse plug-in and Developer Tools Hands-on Lab Yocto Project Developer Day San Francisco, 2013 Jessica Zhang Introduction Welcome to the Yocto Project Eclipse plug-in
More informationOpen Source, Incremental Backup for Windows, Step By Step. Tom Scott BarCampLondon2, 17/2/07
Open Source, Incremental Backup for Windows, Step By Step Tom Scott BarCampLondon2, 17/2/07 Tools Cygwin, a Linux emulator rsync, a sync/copy tool Linux file management commands NTFS formatted drive Screenshots
More informationChapter 1: Getting Started
Chapter 1: Getting Started Every journey begins with a single step, and in ours it's getting to the point where you can compile, link, run, and debug C++ programs. This depends on what operating system
More informationHadoop Shell Commands
Table of contents 1 FS Shell...3 1.1 cat... 3 1.2 chgrp... 3 1.3 chmod... 3 1.4 chown... 4 1.5 copyfromlocal...4 1.6 copytolocal...4 1.7 cp... 4 1.8 du... 4 1.9 dus...5 1.10 expunge...5 1.11 get...5 1.12
More informationIEEEXTREME PROGRAMMING COMPETITION PROBLEM & INSTRUCTION BOOKLET #3
IEEEXTREME PROGRAMMING COMPETITION 2008 PROBLEM & INSTRUCTION BOOKLET #3 Instructions Read all the problems carefully. Each of the problems has a problem number (shown on top), a title, an approximate
More informationBasic Linux & Package Management. Original slides from GTFO Security
Basic Linux & Package Management Original slides from GTFO Security outline Linux What it is? Commands Filesystem / Shell Package Management Services run on Linux mail dns web central authentication router
More informationNetwork Detective Client Connector
Network Detective Copyright 2014 RapidFire Tools, Inc. All Rights Reserved. v20140801 Overview The Network Detective data collectors can be run via command line so that you can run the scans on a scheduled
More informationHow to start with 3DHOP
How to start with 3DHOP Package content, local setup, online deployment http://3dhop.net 30/6/2015 The 3DHOP distribution Where to find it, what s inside The 3DHOP distribution package From the page http://3dhop.net/download.php
More informationPuTTY/Cygwin Tutorial. By Ben Meister Written for CS 23, Winter 2007
PuTTY/Cygwin Tutorial By Ben Meister Written for CS 23, Winter 2007 This tutorial will show you how to set up and use PuTTY to connect to CS Department computers using SSH, and how to install and use the
More informationHDFS File System Shell Guide
Table of contents 1 Overview...3 1.1 cat... 3 1.2 chgrp... 3 1.3 chmod... 3 1.4 chown... 4 1.5 copyfromlocal...4 1.6 copytolocal...4 1.7 count... 4 1.8 cp... 4 1.9 du... 5 1.10 dus...5 1.11 expunge...5
More informationlug create and edit TeX Local User Group web pages
lug create and edit TeX Local User Group web pages doc generated from the script with gendoc bash script, version=2.01 Synopsis lug [options] [lug-code] lug can be used to maintain the TeX Local User Group
More informationThe Linux Operating System and Linux-Related Issues
Review Questions: The Linux Operating System and Linux-Related Issues 1. Explain what is meant by the term copyleft. 2. In what ways is the Linux operating system superior to the UNIX operating system
More informationCLC Server Command Line Tools USER MANUAL
CLC Server Command Line Tools USER MANUAL Manual for CLC Server Command Line Tools 2.5 Windows, Mac OS X and Linux September 4, 2015 This software is for research purposes only. QIAGEN Aarhus A/S Silkeborgvej
More informationWelcome to Introduction to programming in Python
Welcome to Introduction to programming in Python Suffolk One, Ipswich, 4:30 to 6:00 Tuesday Jan 14, Jan 21, Jan 28, Feb 11 Welcome Fire exits Toilets Refreshments 1 Learning objectives of the course An
More informationOpen Source Computational Fluid Dynamics
Open Source Computational Fluid Dynamics An MSc course to gain extended knowledge in Computational Fluid Dynamics (CFD) using open source software. Teachers: Miklós Balogh and Zoltán Hernádi Department
More informationYocto Project ADT, Eclipse plug-in and Developer Tools
Yocto Project ADT, Eclipse plug-in and Developer Tools Jessica Zhang LinuxCon - Japan Tokyo 2013 Agenda The Application Development Toolkit Usage Flow And Roles Yocto Project Eclipse Plug-in Interacts
More informationTable of Contents. The RCS MINI HOWTO
Table of Contents The RCS MINI HOWTO...1 Robert Kiesling...1 1. Overview of RCS...1 2. System requirements...1 3. Compiling RCS from Source...1 4. Creating and maintaining archives...1 5. ci(1) and co(1)...1
More informationCygwin: getting the setup tool
Cygwin: getting the setup tool Free, almost complete UNIX environment emulation for computers running MS Windows. Very handy. 1 First, go to the Cygwin Site: http://www.cygwin.org/cygwin/ Download the
More informationFile System Shell Guide
Table of contents 1 Overview...3 1.1 cat... 3 1.2 chgrp... 3 1.3 chmod... 3 1.4 chown... 4 1.5 copyfromlocal...4 1.6 copytolocal...4 1.7 count... 4 1.8 cp... 5 1.9 du... 5 1.10 dus...5 1.11 expunge...6
More informationgrep, awk and sed three VERY useful command-line utilities Matt Probert, Uni of York grep = global regular expression print
grep, awk and sed three VERY useful command-line utilities Matt Probert, Uni of York grep = global regular expression print In the simplest terms, grep (global regular expression print) will search input
More information