Command-Line Operations : The Shell. Don't fear the command line...



Similar documents
Command Line - Part 1

1 Basic commands. 2 Terminology. CS61B, Fall 2009 Simple UNIX Commands P. N. Hilfinger

Linux command line. An introduction to the Linux command line for genomics. Susan Fairley

Command Line Crash Course For Unix

Unix Guide. Logo Reproduction. School of Computing & Information Systems. Colours red and black on white backgroun

Introduction to Mac OS X

Tutorial Guide to the IS Unix Service

An Introduction to the Linux Command Shell For Beginners

An Introduction to Using the Command Line Interface (CLI) to Work with Files and Directories

Linux Overview. Local facilities. Linux commands. The vi (gvim) editor

Tutorial 0A Programming on the command line

CS 103 Lab Linux and Virtual Machines

CSIL MiniCourses. Introduction To Unix (I) John Lekberg Sean Hogan Cannon Matthews Graham Smith. Updated on:

Unix Sampler. PEOPLE whoami id who

University of Toronto

your Apple warranty; see There are two main failure modes for a mirrored RAID 1 set:

Installing FEAR on Windows, Linux, and Mac Systems

Linux Labs: mini survival guide

RECOVER ( 8 ) Maintenance Procedures RECOVER ( 8 )

Cloud Storage Service

CPSC2800: Linux Hands-on Lab #3 Explore Linux file system and file security. Project 3-1

List of FTP commands for the Microsoft command-line FTP client

Introduction to the UNIX Operating System and Open Windows Desktop Environment

Lab 1 Beginning C Program

A UNIX/Linux in a nutshell

Opening a Command Shell

Birmingham Environment for Academic Research. Introduction to Linux Quick Reference Guide. Research Computing Team V1.0

Week Overview. Running Live Linux Sending from command line scp and sftp utilities

Using a login script for deployment of Kaspersky Network Agent to Mac OS X clients

Unix the Bare Minimum

Chapter 2 Text Processing with the Command Line Interface

File Management Where did it go? Teachers College Summer Workshop

CMSC 216 UNIX tutorial Fall 2010

Hadoop Basics with InfoSphere BigInsights

New Lab Intro to KDE Terminal Konsole

Open Source Computational Fluid Dynamics

Kernel. What is an Operating System? Systems Software and Application Software. The core of an OS is called kernel, which. Module 9: Operating Systems

CGS 1550 File Transfer Project Revised 3/10/2005

FTP File Transfer Protocol as It Relates to ACBL Unit 547 by Bob Gruber

AN INTRODUCTION TO UNIX

Lab 1: Introduction to C, ASCII ART and the Linux Command Line Environment

WebDisk Essentials How to Post & Retrieve Files From Your Own Online Storage Area

Chapter Contents. Operating System Activities. Operating System Basics. Operating System Activities. Operating System Activities 25/03/2014

Operating System Today s Operating Systems File Basics File Management Application Software

Programming for GCSE Topic H: Operating Systems

UNIX Basics. Ian Darwin TCP Informatics January, Presented from a Mac using Apple s Keynote presentation software

Version Control with Subversion and Xcode

Thirty Useful Unix Commands

Computer Systems and Networks. ECPE 170 Jeff Shafer University of the Pacific. Linux Basics

How To Use The Librepo Software On A Linux Computer (For Free)

Unix Primer - Basic Commands In the Unix Shell

1 Introduction. 2 Project Browser. 3 FlowStone Editor

Installing Sun's VirtualBox on Windows XP and setting up an Ubuntu VM

sftp - secure file transfer program - how to transfer files to and from nrs-labs

Getting Started with Command Prompts

Introduction to Unix Tutorial

User Manual for Data Backups

Instructions for Accessing the Advanced Computing Facility Supercomputing Cluster at the University of Kansas

TNM093 Practical Data Visualization and Virtual Reality Laboratory Platform

WinSCP PuTTY as an alternative to F-Secure July 11, 2006

Linux System Administration on Red Hat

CS 2112 Lab: Version Control

A Crash Course on UNIX

PuTTY/Cygwin Tutorial. By Ben Meister Written for CS 23, Winter 2007

For Active Directory Installation Guide

Add page numbers and headers and footers by using the gallery, or create a custom page number, header, or footer.

MOVES Batch Mode: Setting up and running groups of related MOVES run specifications. EPA Office of Transportation and Air Quality 11/3/2010

CLC Server Command Line Tools USER MANUAL

File Manager User Guide

for Networks Installation Guide for thin client package on workstations September 2015 (GUIDE 3) Version 1.3-N

Beyond Windows: Using the Linux Servers and the Grid

LECTURE-7. Introduction to DOS. Introduction to UNIX/LINUX OS. Introduction to Windows. Topics:

Cisco Networking Academy Program Curriculum Scope & Sequence. Fundamentals of UNIX version 2.0 (July, 2002)

IBM Software Hadoop Fundamentals

Version control. HEAD is the name of the latest revision in the repository. It can be used in subversion rather than the latest revision number.

The Einstein Depot server

Xcode Project Management Guide. (Legacy)

An Introduction to Using the Command Line Interface (CLI) to Work with Files and Directories

File Management Windows

Using the Synchronization Client

WS_FTP Professional 12

HP-UX Essentials and Shell Programming Course Summary

Introduction to Operating Systems

A+ Guide to Managing and Maintaining Your PC, 7e. Chapter 2 Introducing Operating Systems

Basic Linux & Package Management. Original slides from GTFO Security

UNIX (LINUX) PRACTICAL 1 INTRODUCTION

SFXCL Automation Tips

Most of your tasks in Windows XP will involve working with information

2 Advanced Session... Properties 3 Session profile... wizard. 5 Application... preferences. 3 ASCII / Binary... Transfer

Microsoft. File Management. Windows Desktop. Microsoft File Management NCSEA

Cluster Computing With R

Running your first Linux Program

Open Source, Incremental Backup for Windows, Step By Step. Tom Scott BarCampLondon2, 17/2/07

Please note that a username and password will be made available upon request. These are necessary to transfer files.

Transcription:

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 folders - Interact with programs in an intuitive way Potential disadvantes : - unpractical for long sequence of operations with different or repeated datastes - No storage of commands are not denoted in a 'log-book' for all user commands, bad repeatibility - GUI's are unsuitable for cluster analysis on different computers - GUI's are not universal, only work on the operating system of choice Command lines can deal with this...

Starting (the S)hell Starting the shell Shells are the programs that display the command line In OS X there are different shells, the default one: bash shell Type: SHELL A command-line view of the file-system File-system : nested hierarchy of folders root directory : most inclusive folder, contains all other files and folders Not to be confused with multiple roots (c:, d:, in dos), desktop, or home directory The path /Users/lang/Documents/asymmetry/Literature/data.txt absolute / relative paths

Starting (the S)hell The path absolute path /Users/lang/Documents/asymmetry/Literature/data.txt Working directory : the one you are currently in Relative path : relative to the working directory /asymmetry/literature/data.txt when working directory is: /Users/lang/Documents/

Navigating your computer from the shell Listing files with 'ls' and figuring out where you are with 'pwd' Open the terminal, starts with home directory Command : ls (list) type : ls Bureau Command : pwd (print working directory) tells you where you are Command cd (change directory, move around) Type : cd directory to move into a nested diretory, cd.. to move back or up Type : cd ~/... Directory to jump directly into it instead fo writing the absolute path Type : cd ~, to go home...

Navigating your computer from the shell Adding and removing directories with 'mkdir' and 'rmdir' Type : mkdir... (make directory) Type : rmdir... (remove directory) they are really deleted, not just in the trash copying files type : cp original.txt copy.txt (copies the file with a name change) type : cp original.txt / path (copies the file into a different directory) cd into a new directoy type : cp path/original.txt./ (moves file from another direcory into this one)

Navigating your computer from the shell moving files type : mv original.txt copy.txt (renames the file) type : mv original.txt / path (moves file into a different directory) cd into a new directoy type : mv path/original.txt./ (moves file from another direcory into this one)

Command line shortcuts Up arrow, Tab Try it out avoid usage of names for folder and files with speces Will be replaced in the command line by \ space,

Modifying command behaviour with arguments Ls, cd, pwd, are little programs that read in bits of information do sth. Pieces of information, passed to a program at the command line are called arguments Different arguments: type : ls type : ls -a type : ls -l type : ls -a -l lists files and folders lists files and folders, plus hidden.folders lists files and folders with indication of hierarchy of permission to read, to read (r) and write (w) and date of storage the ultimate information

Viewing file contents with 'less' To launch a file Type : less filename Navigate with : q quit Space next page b back page ##g go to line ## G go to end scroll up and down /abc search for text abc n Find next abc? Find previous abc h help

Viewing help files at the command line with 'man' Type : man ls man uses less to diplay the manual, so navigate with the same commands: q quit Space next page b back page ##g go to line ## G go to end scroll up and down /abc search for text abc n Find next abc? Find previous abc h help

The command line finally makes your life 'easier' Wildcards in path descriptions * = any number, character (except slash), (in regular expressions :.* Type : ls D* Type : ls *.txt Type : ls D*/*.txt Type : ls D*/*/*.txt lists all documents that begin with D lists all txt files lists all txt.files that are inside a directory that starts with D lists all txt.files in a directory inside a D... directory Copying and moving multiple files Type : cp../path/*.txt./ copies all txt.files from a specified directory into the working directory

Ending your terminal session Type : exit (sometimes logout or quit)