Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 9304c12

Browse files
Small edits to Unix lecture to sync with Jupyter
1 parent 1124504 commit 9304c12

File tree

1 file changed

+32
-14
lines changed

1 file changed

+32
-14
lines changed

‎notes/unix_outline.org‎

Lines changed: 32 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -607,7 +607,7 @@ Here, let us explore powerful tools to manipulate text files. Many of these
607607
functions are available in Python and R, but here we can show the exact same
608608
functionality with time-tested tools.
609609

610-
** awk
610+
** awk - text processing language with strength in tabular data
611611

612612
The ~awk~ command line tool is a powerful tool for processing text files,
613613
especially those organized into rows and columns i.e. tabular data.
@@ -689,8 +689,10 @@ total 113
689689
- [[https://www.lifewire.com/write-awk-commands-and-scripts-2200573][How to Write AWK Commands and Scripts]]
690690
- [[https://www.thegeekstuff.com/2010/01/8-powerful-awk-built-in-variables-fs-ofs-rs-ors-nr-nf-filename-fnr/][8 Powerful Awk Built-in Variables (The Geek Stuff)]]
691691
- [[http://www.grymoire.com/Unix/Awk.html][Awk (Grymoire)]]
692+
- [[https://ss64.com/bash/awk.html][awk or gawk (GNU awk)]]
693+
- [[https://github.com/learnbyexample/Command-line-text-processing/blob/master/gnu_awk.md][Learn by Example awk]]
692694

693-
** sed
695+
** sed - edit streams of text
694696

695697
The ~sed~ command is another powerful command. While ~awk~ is useful for
696698
manipulating tabular data, ~sed~ is used to read in text and transform it.
@@ -707,8 +709,9 @@ A simple use of ~sed~ is for replacing text.
707709
*** Resources and more
708710

709711
- [[http://www.grymoire.com/Unix/Sed.html][sed (Grymoire)]]
712+
- [[https://ss64.com/bash/sed.html][sed (SS64)]]
710713

711-
** cut
714+
** cut - divide file into several parts by columns/delimiter
712715

713716
The ~cut~ command is useful to divide a file into several parts.
714717

@@ -737,15 +740,15 @@ total 113
737740
-rw-r--r--
738741
:END:
739742

740-
** sort
743+
** sort - put items in order
741744

742745
As the name implies, the ~sort~ command will order a list of items.
743746

744747
#+BEGIN_SRC sh
745748
ls | sort
746749
#+END_SRC
747750

748-
** find
751+
** find - search for files
749752

750753
The ~find~ command will be helpful to search for files.
751754

@@ -1093,7 +1096,7 @@ When working with a server, you may want to move files between your own
10931096
computer and the server. While there are graphical tools to do this, there are
10941097
command line tools available to you to do this as well.
10951098

1096-
** curl and wget
1099+
** curl and wget retrieve files from servers
10971100

10981101
~curl~ and ~wget~ are both command line tools that can download contents from
10991102
servers and the internet.
@@ -1133,7 +1136,7 @@ For simple file downloads, there isn't much of a difference in use.
11331136
- [[https://www.cyberciti.biz/faq/curl-download-file-example-under-linux-unix/][Linux/Unix: curl Command Download File Example]]
11341137
- [[https://www.cyberciti.biz/tips/linux-wget-your-ultimate-command-line-downloader.html][Linux wget: Your Ultimate Command Line Downloader]]
11351138

1136-
** scp and sftp
1139+
** scp and sftp for secure transfer of files
11371140

11381141
~scp~ and ~sftp~ are both useful command line tools to move files between
11391142
servers/computers.
@@ -1231,7 +1234,7 @@ Here are some benefits to using a terminal multiplexer:
12311234
- Use when network connection unreliable
12321235
- Pick up progress quickly on a server when you login
12331236

1234-
**** Screen
1237+
*** Screen
12351238

12361239
Initially releases in 1987, Screen is a mature and stable terminal
12371240
multiplexer.
@@ -1267,7 +1270,7 @@ is a list of commands to use while in screen.
12671270
| Ctrl+a " | Switch between terminals using list |
12681271
| Ctrl+a ? | Display list of all commands |
12691272

1270-
**** tmux
1273+
*** tmux
12711274

12721275
Initially created in 2007, tmux is also a terminal multiplexer with very
12731276
similar features compared to Screen.
@@ -1317,7 +1320,7 @@ The main key to invoke changes in tmux is ~Ctrl+b~.
13171320
- More
13181321
- [[https://leanpub.com/the-tao-of-tmux/read][The Tao of tmux - Leanpub]]
13191322

1320-
** GNU Make
1323+
** GNU Make for automation
13211324

13221325
In programming, we want to no repeat ourselves. So people made GNU ~make~ as an
13231326
automation (build) tool.
@@ -1455,7 +1458,7 @@ The data can be found [[https://archive.ics.uci.edu/ml/machine-learning-database
14551458

14561459
** Exercise 3 Search for Codons
14571460

1458-
Using the random DNA seqence Python script from Exercise 1, generate a random
1461+
Using the random DNA sequence Python script from Exercise 1, generate a random
14591462
sequence of DNA and count the number of times the DNA sequence "TAA" (a stop
14601463
codon).
14611464

@@ -1464,10 +1467,25 @@ count them each.
14641467

14651468
* Resources and More
14661469

1470+
- [[https://github.com/learnbyexample/Linux_command_line][Linux Commands and Shell Scripting - learnbyexample]]: overview of Linux and
1471+
commonly found commands
1472+
- [[https://github.com/learnbyexample/Command-line-text-processing][Command Line Text Processing - learnbyexample]]: from finding text to search
1473+
and replace, from sorting to beautifying text and more
1474+
- [[http://tldp.org/LDP/abs/html/][Advanced Bash Scripting Guide]]: an in-depth exploration of the art of shell
1475+
scripting
1476+
- [[https://github.com/stephenturner/oneliners][Bioinformatics One-Liners by Stephen Turner]]: useful bash one-liners usesful
1477+
for bioinformatics
1478+
- [[https://github.com/jlevy/the-art-of-command-line][The Art of Command Line]]: guide for both beginners and the experienced, with
1479+
goals of **breadth** (everything important), **specificity** (give concrete
1480+
examples of the most common case), and **brevity** (avoid things that aren't
1481+
essential or digressions you can easily look up elsewhere
1482+
- [[https://github.com/denysdovhan/bash-handbook][bash-handbook (GitHub)]]: document for those who want to learn Bash without
1483+
diving in too deeply.
1484+
- [[https://github.com/awesome-lists/awesome-bash][Awesome Bash (GitHub)]]: a curated list of delightful Bash scripts and
1485+
resources
1486+
- [[https://twitter.com/i/moments/1026078161115729920][Julia Evans' (@b0rk) Twitter snippets]]: scroll through her photos for hand
1487+
drawn descriptions of bash and others
14671488
- [[http://tldp.org/LDP/Bash-Beginners-Guide/html/index.html][Bash Guide for Beginners]] (Beginner)
14681489
- [[http://tldp.org/HOWTO/Bash-Prog-Intro-HOWTO.html][BASH Programming - Introduction HOW-TO]] (Intermediate)
1469-
- [[https://github.com/stephenturner/oneliners][Bioinformatics One-Liners by Stephen Turner]]
14701490
- [[http://mywiki.wooledge.org/BashPitfalls][Bash Pitfalls - Common Errors Bash Programmers Make]]
1471-
- [[https://github.com/denysdovhan/bash-handbook][bash-handbook (GitHub)]]
14721491
- [[https://sanctum.geek.nz/arabesque/series/unix-as-ide/][Unix as IDE Series]]
1473-
- [[https://github.com/awesome-lists/awesome-bash][Awesome Bash (GitHub)]]

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /