SlideShare a Scribd company logo
Ultimate UNIX Setup
For Developers
Jacob Menke โ€“ Software Engineer && Business ComputerTechnologies LabTechnician (Ann Arbor MI)
Boring and not too usable
defaultsโ€ฆ
Ultimate Unix Meetup Presentation
Config Files &&YouTubeTutorials
โ€ข https://github.com/MenkeTechnologies/TutorialFiles
โ€ข https://www.youtube.com/channel/UCLOQFBXPrcVvO2
Wb3wna8Ow
โ€ข RecentTopics : GNU Readline Shortcuts in mysql,
python3 and various REPLs
โ€ข http://jakobmenke.com/
Custom Shell functions
โ€ข cd
โ€ข aliases > functions > reserved words > builtins > external
commands in PATH > not found
โ€ข clearList == bash function
โ€ข essentially: clear && ls -AlhFi
Functions and aliases
UNIX Spirit โ€“ One letter commands. The more cryptic and less typing the better
Aliases Demo
Package Managers
โ€ข Mac => Homebrew, MacPorts, Fink (old)
โ€ข Homebrew HomePage => https://brew.sh/
โ€ข install => /usr/bin/ruby -e "$(curl -fsSL
https://raw.githubusercontent.com/Homebrew/install/ma
ster/install)"
Homebrew Jargon
โ€ข Package == Formula == ruby file
โ€ข installed into /usr/local/Cellar/<package> with symlinks into
/usr/local/bin, /usr/local/lib etc
โ€ข Taps == Github repositories
โ€ข Homebrew Core Repo Formulae
โ€ข downloaded to /usr/local/Homebrew/Library/taps/homebrew/homebrew-
core/formula
โ€ข Bottle == binary program already built for macOS (configure and make
already done for you)
โ€ข Cask == GUI program or font ie microsoft-office, intellij-idea
Homebrew Formula
brew install zzz
Homebrew Exploration
Homebrew
โ€ข brew install <package>
โ€ข brew ls
โ€ข brew rm <package>
โ€ข brew search <package>
โ€ข brew cleanup
โ€ข brew update
โ€ข brew upgrade
โ€ข brew cask install <gui-package>
โ€ข Brew cask rm <gui-package>
(removes .app from /Applications)
โ€ข brew cask zap <gui-package> (like
brew cask rm but also removes all
preferences files etc ie full
deinstallation)
โ€ข brew cask rm <gui>
Homebrew Demo
Package Managers
โ€ข Linux
โ€ข Debian based = Debian, Ubuntu, Mint, Raspbian, Kali
โ€ข Dpkg, apt, aptitude
โ€ข RPM based = Red Hat, Fedora, CentOS
โ€ข Rpm, yum
Apt
โ€ข sudo apt-get install <package>
โ€ข sudo apt-cache search <package>
โ€ข sudo apt-get purge <package>
โ€ข dpkg โ€“l = list all installed packages
โ€ข dpkg โ€“L <package> = show files for this package
โ€ข sudo apt-get update
โ€ข sudo apt-get upgrade
Tmux
โ€ข Terminal Multiplexer
โ€ข brew install tmux
โ€ข sudo apt-get install tmux
Ultimate Unix Meetup Presentation
Ultimate Unix Meetup Presentation
Ultimate Unix Meetup Presentation
Ultimate Unix Meetup Presentation
Tmux Commands
โ€ข tmux = start server
โ€ข tmux new-session โ€“t <session-name>
โ€ข tmux new-window โ€“t <window-name>
โ€ข tmux split-window = horizontal split pane
โ€ข tmux list-sessions (tmux ls) = list sessions
โ€ข tmux list-windows
โ€ข tmux list-panes
Tmux Commands
โ€ข tmux attach โ€“t <session-name>
โ€ข tmux kill-session [โ€“t <session-name>]
โ€ข tmux kill-window [โ€“t <window-name>]
โ€ข tmux kill-pane [โ€“t <pane>]
Tmux Demo
Inside ofTmux
โ€ข Prefix = defaults to ^B (Control B) but can be changed
โ€ข <prefix> + % => vertical split
โ€ข <prefix> + โ€œ = horizontal split
โ€ข <prefix> + c = new window
โ€ข <prefix> + n = next window
โ€ข <prefix> + p = previous window
โ€ข <prefix> + : => command line inside tmux similar to vim
โ€ข <prefix> + : then kill-pane = kills current pane
โ€ข === tmux kill-pane
~/.tmux.conf
โ€ข Prefix = defaults to control b but can be changed
โ€ข These lines bind:
โ€ข prefix to ^a
โ€ข <prefix> - | to split vertically
โ€ข <prefix> - - to split horizontally
Tmux Demo
Tmux scripts
โ€ข usually located in ~/.tmux directory
โ€ข list of tmux commands to run
โ€ข could be run as tmux selectp โ€“t 0 or <prefix>+: selectp โ€“t 0
โ€ข ~/.tmux/four-panes
โ€ข ~/.tmux.conf
ControlWindow script
Tmux Demo
Htop
โ€ข brew install htop
โ€ข sudo apt-get install htop
โ€ข Similar to top but shows core usages
โ€ข / to search
โ€ข space to tag process
โ€ข k to kill process
Htop demo
ccze
โ€ข brew install ccze
โ€ข sudo apt-get install ccze
โ€ข tail โ€“f /var/log/**/*.log | ccze
โ€ข sudo id = shows up in /var/log/system.log on Mac and
/var/log/auth.log on Linux
Logging with color bash script
ccze demo
iftop
โ€ข brew install iftop
โ€ข sudo apt-get install iftop
โ€ข sudo iftop โ€“c ~/.iftop.conf
โ€ข while running:
โ€ข t = toggle bar display modes
โ€ข q = quit
โ€ข f = filter
โ€ข h = help
~/.iftop.conf
โ€ข port-display:on
โ€ข line-display:one-line-both
โ€ข interface: en0
iftop - colorized
โ€ข git clone
https://github.com/MenkeTechnologies/iftopcolor
โ€ข ./configure && make
โ€ข sudo make install or move executable ./iftop to
somewhere in PATH
iftop demo
grc โ€“ general colorizer
โ€ข https://github.com/garabik/grc
โ€ข brew install grc
โ€ข sudo apt-get install grc
grc config files
โ€ข Mac: /usr/local/share/grc/conf.ls
โ€ข Linux:/usr/share/grc/conf.ls
โ€ข each command that will be colorized has its
corresponding config file
โ€ข automatic aliases
โ€ข usage: grc netstat
โ€ข grc โ€“c /usr/local/share/grc/conf.ls ping google.com
Automatic Aliasing (Over aliases)
โ€ข curl https://raw.githubusercontent.com/garabik/grc/master/grc.zsh -
O $HOME/grc.zsh
โ€ข ~/.zshrc : [[ -s โ€$HOME/grc.zsh" ]] && source
โ€œ$HOME/grc.zshโ€
โ€ข ping is now alias for grc ping
grc uses regex for colorization
grc demo
โ€ข ping
โ€ข ifconfig
โ€ข dd
โ€ข ps
Python programs
โ€ข Glances = pip package
โ€ข Powerline status = pip package
โ€ข brew install python = goes into
/usr/local/Cellar/python/<version-number>
โ€ข pip, package manager for python, should be included
โ€ข Mac: pip installs packages to /usr/local/lib/python2.7/site-
packages on
โ€ข Debian: pip installs packages to /usr/local/lib/python2.7/dist-
packages
Pip exploration
pip
โ€ข pip install <package>
โ€ข pip show <package>
โ€ข for package in $(pip list โ€“outdated);do pip install
$package done
Powerline
โ€ข Status bars for vim, tmux
โ€ข requires special fonts for triangles such as Nerd Fonts
โ€ข https://github.com/ryanoasis/nerd-fonts
โ€ข pip install powerline-status
โ€ข ~/.tmux.conf
โ€ข ~/.vimrc
Powerline forVim
โ€ข recommend to install latest vim 8+
โ€ข brew install vim
โ€ข sudo apt-get install vim
โ€ข brew install macvim (fastest for mac IMO)
โ€ข mvim โ€“v <file> = stay in terminal
โ€ข mvim <file> = launch gui
Powerline forVim
Macvim Demo
PowerlineTmux Status Bar
โ€ข http://powerline.readthedocs.io/en/master/usage/other.h
tml#tmux-statusline
โ€ข Define tmux status line in JSON file =>
โ€ข $HOME/.config/powerline/themes/tmux
PowerlineTmux StatusBar Demo
My Prompt == Powerlevel 9k
โ€ข https://github.com/bhilburn/power
level9k
โ€ข using Knack Nerd Font
โ€ข brew tap caskroom/fonts
โ€ข brew cask install font-hacknerd-
font
Powerlevel9k prompt config
Prompt Demo
glances
โ€ข pip install glances
โ€ข on Mac installs to /usr/local/lib/python2.7/site-
packages/glances
โ€ข Debian installs to /usr/local/lib/python2.7/dist-packages
โ€ข https://github.com/nicolargo/glances
glances
โ€ข sudo glances [--disable-alert] [--disable-network] [โ€ฆ]
โ€ข To change text color from white to blue:
โ€ข Change line 203 in glances/outputs/glances_curses.py
โ€ข curses.init_pair(1, curses.COLOR_WHITE, -1)=>
โ€ข curses.init_pair(1, curses.COLOR_BLUE, -1)
glances demo
Oh-my-zsh
โ€ข Framework for zsh, geared toward developers
โ€ข Tons of prompts and plugins
โ€ข https://github.com/robbyrussell/oh-my-zsh
Oh my zsh install
โ€ข sh -c "$(curl -fsSL
https://raw.githubusercontent.com/robbyrussell/oh-my-
zsh/master/tools/install.sh)โ€
Oh my zsh Plugins
โ€ข git clone into ~/.oh-my-zsh/custom/plugins
โ€ข add to plugins array ~/.zshrc
Zsh-autosuggestions
โ€ข copy of FISH (friendly interactive shell)โ€™s suggestions
โ€ข Searches history (~/.zsh-history) for most recent commands
starting with letters typed
โ€ข hit right arrow to complete the suggestion
โ€ข git clone https://github.com/zsh-users/zsh-autosuggestions
$ZSH_CUSTOM/plugins/zsh-autosuggestions
โ€ข add to plugins array in ~/.zshrc
Zsh-syntax highlighting
โ€ข Red if invalid command, green if found in PATH
โ€ข highlighting for quotes
โ€ข git clone https://github.com/zsh-users/zsh-syntax-
highlighting.git ${ZSH_CUSTOM:-~/.oh-my-
zsh/custom}/plugins/zsh-syntax-highlighting
โ€ข add to plugins array in ~/.zshrc
Zsh-completions
โ€ข adds zsh completions for more commands
โ€ข Adds zsh tab completions for many more commands such as caffeinate
โ€ข git clone https://github.com/zsh-users/zsh-completions ~/.oh-my-
zsh/custom/plugins/zsh-completions
โ€ข add to plugins array in ~/.zshrc
zsh plugins demo
z command
โ€ข creates database of visited directories
โ€ข usage: z <directory-name>
โ€ข directory-name can be just a few letters of the name
โ€ข if there is a match you will cd to that directory otherwise
no cd and returns 1
z install
โ€ข git clone
https://raw.githubusercontent.com/rupa/z/master/z.sh
$HOME
โ€ข source ~/z.sh
Zle line editor in ~/.zshrc
3) declare zsh function
as widget
4) Bind widget
function to Control-S
key combination
1) Define zsh function
2) Define zsh function to be
bound as widget. Calls above
function with the contents of
current command line as
argument
Type your commit
message at prompt no
quotes needed and
then pressControl-S
to add, commit and
push to remote
z and ZLE demo
Ad

Recommended

Fabric Fast & Furious edition
Fabric Fast & Furious edition
Alejandro E Brito Monedero
ย 
Changelog
Changelog
AsNoticiasnoticia
ย 
Elephant bird build Error
Elephant bird build Error
Kapil Dewade
ย 
Linux kernel debugging
Linux kernel debugging
Hao-Ran Liu
ย 
Really useful linux commands
Really useful linux commands
Michael J Geiser
ย 
Network Security Testing Tools
Network Security Testing Tools
praveen_recker
ย 
Dev8d 2011-pipe2 py
Dev8d 2011-pipe2 py
Tony Hirst
ย 
Linux Initialization Process (2)
Linux Initialization Process (2)
shimosawa
ย 
Deploying Symfony2 app with Ansible
Deploying Symfony2 app with Ansible
Roman Rodomansky
ย 
Hadoop Installation
Hadoop Installation
mrinalsingh385
ย 
Kernel Recipes 2017: Using Linux perf at Netflix
Kernel Recipes 2017: Using Linux perf at Netflix
Brendan Gregg
ย 
JavaOne 2015 Java Mixed-Mode Flame Graphs
JavaOne 2015 Java Mixed-Mode Flame Graphs
Brendan Gregg
ย 
Ansible - simple it automation
Ansible - simple it automation
Larry Nung
ย 
Tutorial: Cross-compiling Linux Kernels on x86_64
Tutorial: Cross-compiling Linux Kernels on x86_64
Samsung Open Source Group
ย 
Hadoop installation
Hadoop installation
Leon Gladston
ย 
Linux Network commands
Linux Network commands
Hanan Nmr
ย 
Introduction to linux
Introduction to linux
QIANG XU
ย 
More than Applications: (Ab)using Docker to Improve the Portability of Everyt...
More than Applications: (Ab)using Docker to Improve the Portability of Everyt...
Dexter Horthy
ย 
Light my-fuse
Light my-fuse
Workhorse Computing
ย 
PHP Dependency Management with Composer
PHP Dependency Management with Composer
Adam Englander
ย 
Dependency management with Composer
Dependency management with Composer
Jason Grimes
ย 
Testing Your Automation Code (Vagrant Version)
Testing Your Automation Code (Vagrant Version)
Mischa Taylor
ย 
An example Hadoop Install
An example Hadoop Install
Mike Frampton
ย 
Building RT image with Yocto
Building RT image with Yocto
Alexandre LAHAYE
ย 
Setting up a local WordPress development environment
Setting up a local WordPress development environment
Zero Point Development
ย 
Installing and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command line
dotCloud
ย 
Dockerizing WordPress
Dockerizing WordPress
dotCloud
ย 
Ultimate Unix Meetup Presentation
Ultimate Unix Meetup Presentation
JacobMenke1
ย 
Unleash your inner console cowboy
Unleash your inner console cowboy
Kenneth Geisshirt
ย 
Unleash your inner console cowboy
Unleash your inner console cowboy
Kenneth Geisshirt
ย 

More Related Content

What's hot (19)

Deploying Symfony2 app with Ansible
Deploying Symfony2 app with Ansible
Roman Rodomansky
ย 
Hadoop Installation
Hadoop Installation
mrinalsingh385
ย 
Kernel Recipes 2017: Using Linux perf at Netflix
Kernel Recipes 2017: Using Linux perf at Netflix
Brendan Gregg
ย 
JavaOne 2015 Java Mixed-Mode Flame Graphs
JavaOne 2015 Java Mixed-Mode Flame Graphs
Brendan Gregg
ย 
Ansible - simple it automation
Ansible - simple it automation
Larry Nung
ย 
Tutorial: Cross-compiling Linux Kernels on x86_64
Tutorial: Cross-compiling Linux Kernels on x86_64
Samsung Open Source Group
ย 
Hadoop installation
Hadoop installation
Leon Gladston
ย 
Linux Network commands
Linux Network commands
Hanan Nmr
ย 
Introduction to linux
Introduction to linux
QIANG XU
ย 
More than Applications: (Ab)using Docker to Improve the Portability of Everyt...
More than Applications: (Ab)using Docker to Improve the Portability of Everyt...
Dexter Horthy
ย 
Light my-fuse
Light my-fuse
Workhorse Computing
ย 
PHP Dependency Management with Composer
PHP Dependency Management with Composer
Adam Englander
ย 
Dependency management with Composer
Dependency management with Composer
Jason Grimes
ย 
Testing Your Automation Code (Vagrant Version)
Testing Your Automation Code (Vagrant Version)
Mischa Taylor
ย 
An example Hadoop Install
An example Hadoop Install
Mike Frampton
ย 
Building RT image with Yocto
Building RT image with Yocto
Alexandre LAHAYE
ย 
Setting up a local WordPress development environment
Setting up a local WordPress development environment
Zero Point Development
ย 
Installing and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command line
dotCloud
ย 
Dockerizing WordPress
Dockerizing WordPress
dotCloud
ย 
Deploying Symfony2 app with Ansible
Deploying Symfony2 app with Ansible
Roman Rodomansky
ย 
Hadoop Installation
Hadoop Installation
mrinalsingh385
ย 
Kernel Recipes 2017: Using Linux perf at Netflix
Kernel Recipes 2017: Using Linux perf at Netflix
Brendan Gregg
ย 
JavaOne 2015 Java Mixed-Mode Flame Graphs
JavaOne 2015 Java Mixed-Mode Flame Graphs
Brendan Gregg
ย 
Ansible - simple it automation
Ansible - simple it automation
Larry Nung
ย 
Tutorial: Cross-compiling Linux Kernels on x86_64
Tutorial: Cross-compiling Linux Kernels on x86_64
Samsung Open Source Group
ย 
Hadoop installation
Hadoop installation
Leon Gladston
ย 
Linux Network commands
Linux Network commands
Hanan Nmr
ย 
Introduction to linux
Introduction to linux
QIANG XU
ย 
More than Applications: (Ab)using Docker to Improve the Portability of Everyt...
More than Applications: (Ab)using Docker to Improve the Portability of Everyt...
Dexter Horthy
ย 
PHP Dependency Management with Composer
PHP Dependency Management with Composer
Adam Englander
ย 
Dependency management with Composer
Dependency management with Composer
Jason Grimes
ย 
Testing Your Automation Code (Vagrant Version)
Testing Your Automation Code (Vagrant Version)
Mischa Taylor
ย 
An example Hadoop Install
An example Hadoop Install
Mike Frampton
ย 
Building RT image with Yocto
Building RT image with Yocto
Alexandre LAHAYE
ย 
Setting up a local WordPress development environment
Setting up a local WordPress development environment
Zero Point Development
ย 
Installing and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command line
dotCloud
ย 
Dockerizing WordPress
Dockerizing WordPress
dotCloud
ย 

Similar to Ultimate Unix Meetup Presentation (20)

Ultimate Unix Meetup Presentation
Ultimate Unix Meetup Presentation
JacobMenke1
ย 
Unleash your inner console cowboy
Unleash your inner console cowboy
Kenneth Geisshirt
ย 
Unleash your inner console cowboy
Unleash your inner console cowboy
Kenneth Geisshirt
ย 
Mac OSX Terminal 101
Mac OSX Terminal 101
Murugun Murugun
ย 
Unleash your inner console cowboy
Unleash your inner console cowboy
Kenneth Geisshirt
ย 
linux system administration for system admin jobs
linux system administration for system admin jobs
Bibhushanrabha
ย 
Bash Scripting Workshop
Bash Scripting Workshop
Ahmed Magdy Ezzeldin, MSc.
ย 
Complete Guide for Linux shell programming
Complete Guide for Linux shell programming
sudhir singh yadav
ย 
Using the command line on macOS
Using the command line on macOS
AdamFallon4
ย 
BASIC COMMANDS OF LINUX
BASIC COMMANDS OF LINUX
Mr.AKHILESH KUMAR {Computer Lab Technician}
ย 
Working with clusters, shell profiles, UNIX extras..pptx
Working with clusters, shell profiles, UNIX extras..pptx
oliversen
ย 
Mastering the Unix Command Line
Mastering the Unix Command Line
Howard Mao
ย 
Putty
Putty
rajpreet
ย 
js_injwqeweqwqewqewqewqewqewqewqeected_xss.pdf
js_injwqeweqwqewqewqewqewqewqewqeected_xss.pdf
qualwinforhacking
ย 
Topic 3-1_More_Linux_Commands.pptx
Topic 3-1_More_Linux_Commands.pptx
dulala3
ย 
One-Liners to Rule Them All
One-Liners to Rule Them All
egypt
ย 
Linux Commands - Cheat Sheet
Linux Commands - Cheat Sheet
Isham Rashik
ย 
Basic linux commands for bioinformatics
Basic linux commands for bioinformatics
Bonnie Ng
ย 
Aucklug slides - desktop tips and tricks
Aucklug slides - desktop tips and tricks
Glen Ogilvie
ย 
Information about linux operating system
Information about linux operating system
PriyankaMate4
ย 
Ultimate Unix Meetup Presentation
Ultimate Unix Meetup Presentation
JacobMenke1
ย 
Unleash your inner console cowboy
Unleash your inner console cowboy
Kenneth Geisshirt
ย 
Unleash your inner console cowboy
Unleash your inner console cowboy
Kenneth Geisshirt
ย 
Mac OSX Terminal 101
Mac OSX Terminal 101
Murugun Murugun
ย 
Unleash your inner console cowboy
Unleash your inner console cowboy
Kenneth Geisshirt
ย 
linux system administration for system admin jobs
linux system administration for system admin jobs
Bibhushanrabha
ย 
Complete Guide for Linux shell programming
Complete Guide for Linux shell programming
sudhir singh yadav
ย 
Using the command line on macOS
Using the command line on macOS
AdamFallon4
ย 
Working with clusters, shell profiles, UNIX extras..pptx
Working with clusters, shell profiles, UNIX extras..pptx
oliversen
ย 
Mastering the Unix Command Line
Mastering the Unix Command Line
Howard Mao
ย 
Putty
Putty
rajpreet
ย 
js_injwqeweqwqewqewqewqewqewqewqeected_xss.pdf
js_injwqeweqwqewqewqewqewqewqewqeected_xss.pdf
qualwinforhacking
ย 
Topic 3-1_More_Linux_Commands.pptx
Topic 3-1_More_Linux_Commands.pptx
dulala3
ย 
One-Liners to Rule Them All
One-Liners to Rule Them All
egypt
ย 
Linux Commands - Cheat Sheet
Linux Commands - Cheat Sheet
Isham Rashik
ย 
Basic linux commands for bioinformatics
Basic linux commands for bioinformatics
Bonnie Ng
ย 
Aucklug slides - desktop tips and tricks
Aucklug slides - desktop tips and tricks
Glen Ogilvie
ย 
Information about linux operating system
Information about linux operating system
PriyankaMate4
ย 
Ad

Recently uploaded (20)

CapCut Pro Crack For PC Latest Version {Fully Unlocked} 2025
CapCut Pro Crack For PC Latest Version {Fully Unlocked} 2025
pcprocore
ย 
You are not excused! How to avoid security blind spots on the way to production
You are not excused! How to avoid security blind spots on the way to production
Michele Leroux Bustamante
ย 
Cyber Defense Matrix Workshop - RSA Conference
Cyber Defense Matrix Workshop - RSA Conference
Priyanka Aash
ย 
Oh, the Possibilities - Balancing Innovation and Risk with Generative AI.pdf
Oh, the Possibilities - Balancing Innovation and Risk with Generative AI.pdf
Priyanka Aash
ย 
" How to survive with 1 billion vectors and not sell a kidney: our low-cost c...
" How to survive with 1 billion vectors and not sell a kidney: our low-cost c...
Fwdays
ย 
Smarter Aviation Data Management: Lessons from Swedavia Airports and Sweco
Smarter Aviation Data Management: Lessons from Swedavia Airports and Sweco
Safe Software
ย 
PyCon SG 25 - Firecracker Made Easy with Python.pdf
PyCon SG 25 - Firecracker Made Easy with Python.pdf
Muhammad Yuga Nugraha
ย 
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik
ย 
OpenPOWER Foundation & Open-Source Core Innovations
OpenPOWER Foundation & Open-Source Core Innovations
IBM
ย 
Quantum AI Discoveries: Fractal Patterns Consciousness and Cyclical Universes
Quantum AI Discoveries: Fractal Patterns Consciousness and Cyclical Universes
Saikat Basu
ย 
Wenn alles versagt - IBM Tape schรผtzt, was zรคhlt! Und besonders mit dem neust...
Wenn alles versagt - IBM Tape schรผtzt, was zรคhlt! Und besonders mit dem neust...
Josef Weingand
ย 
The Future of Technology: 2025-2125 by Saikat Basu.pdf
The Future of Technology: 2025-2125 by Saikat Basu.pdf
Saikat Basu
ย 
From Manual to Auto Searching- FME in the Driver's Seat
From Manual to Auto Searching- FME in the Driver's Seat
Safe Software
ย 
cnc-processing-centers-centateq-p-110-en.pdf
cnc-processing-centers-centateq-p-110-en.pdf
AmirStern2
ย 
AI Agents and FME: A How-to Guide on Generating Synthetic Metadata
AI Agents and FME: A How-to Guide on Generating Synthetic Metadata
Safe Software
ย 
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Nilesh Gule
ย 
OWASP Barcelona 2025 Threat Model Library
OWASP Barcelona 2025 Threat Model Library
PetraVukmirovic
ย 
Python Conference Singapore - 19 Jun 2025
Python Conference Singapore - 19 Jun 2025
ninefyi
ย 
Quantum AI: Where Impossible Becomes Probable
Quantum AI: Where Impossible Becomes Probable
Saikat Basu
ย 
AI vs Human Writing: Can You Tell the Difference?
AI vs Human Writing: Can You Tell the Difference?
Shashi Sathyanarayana, Ph.D
ย 
CapCut Pro Crack For PC Latest Version {Fully Unlocked} 2025
CapCut Pro Crack For PC Latest Version {Fully Unlocked} 2025
pcprocore
ย 
You are not excused! How to avoid security blind spots on the way to production
You are not excused! How to avoid security blind spots on the way to production
Michele Leroux Bustamante
ย 
Cyber Defense Matrix Workshop - RSA Conference
Cyber Defense Matrix Workshop - RSA Conference
Priyanka Aash
ย 
Oh, the Possibilities - Balancing Innovation and Risk with Generative AI.pdf
Oh, the Possibilities - Balancing Innovation and Risk with Generative AI.pdf
Priyanka Aash
ย 
" How to survive with 1 billion vectors and not sell a kidney: our low-cost c...
" How to survive with 1 billion vectors and not sell a kidney: our low-cost c...
Fwdays
ย 
Smarter Aviation Data Management: Lessons from Swedavia Airports and Sweco
Smarter Aviation Data Management: Lessons from Swedavia Airports and Sweco
Safe Software
ย 
PyCon SG 25 - Firecracker Made Easy with Python.pdf
PyCon SG 25 - Firecracker Made Easy with Python.pdf
Muhammad Yuga Nugraha
ย 
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik
ย 
OpenPOWER Foundation & Open-Source Core Innovations
OpenPOWER Foundation & Open-Source Core Innovations
IBM
ย 
Quantum AI Discoveries: Fractal Patterns Consciousness and Cyclical Universes
Quantum AI Discoveries: Fractal Patterns Consciousness and Cyclical Universes
Saikat Basu
ย 
Wenn alles versagt - IBM Tape schรผtzt, was zรคhlt! Und besonders mit dem neust...
Wenn alles versagt - IBM Tape schรผtzt, was zรคhlt! Und besonders mit dem neust...
Josef Weingand
ย 
The Future of Technology: 2025-2125 by Saikat Basu.pdf
The Future of Technology: 2025-2125 by Saikat Basu.pdf
Saikat Basu
ย 
From Manual to Auto Searching- FME in the Driver's Seat
From Manual to Auto Searching- FME in the Driver's Seat
Safe Software
ย 
cnc-processing-centers-centateq-p-110-en.pdf
cnc-processing-centers-centateq-p-110-en.pdf
AmirStern2
ย 
AI Agents and FME: A How-to Guide on Generating Synthetic Metadata
AI Agents and FME: A How-to Guide on Generating Synthetic Metadata
Safe Software
ย 
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Nilesh Gule
ย 
OWASP Barcelona 2025 Threat Model Library
OWASP Barcelona 2025 Threat Model Library
PetraVukmirovic
ย 
Python Conference Singapore - 19 Jun 2025
Python Conference Singapore - 19 Jun 2025
ninefyi
ย 
Quantum AI: Where Impossible Becomes Probable
Quantum AI: Where Impossible Becomes Probable
Saikat Basu
ย 
AI vs Human Writing: Can You Tell the Difference?
AI vs Human Writing: Can You Tell the Difference?
Shashi Sathyanarayana, Ph.D
ย 
Ad

Ultimate Unix Meetup Presentation

  • 1. Ultimate UNIX Setup For Developers Jacob Menke โ€“ Software Engineer && Business ComputerTechnologies LabTechnician (Ann Arbor MI)
  • 2. Boring and not too usable defaultsโ€ฆ
  • 4. Config Files &&YouTubeTutorials โ€ข https://github.com/MenkeTechnologies/TutorialFiles โ€ข https://www.youtube.com/channel/UCLOQFBXPrcVvO2 Wb3wna8Ow โ€ข RecentTopics : GNU Readline Shortcuts in mysql, python3 and various REPLs โ€ข http://jakobmenke.com/
  • 5. Custom Shell functions โ€ข cd โ€ข aliases > functions > reserved words > builtins > external commands in PATH > not found
  • 6. โ€ข clearList == bash function โ€ข essentially: clear && ls -AlhFi
  • 7. Functions and aliases UNIX Spirit โ€“ One letter commands. The more cryptic and less typing the better
  • 9. Package Managers โ€ข Mac => Homebrew, MacPorts, Fink (old) โ€ข Homebrew HomePage => https://brew.sh/ โ€ข install => /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/ma ster/install)"
  • 10. Homebrew Jargon โ€ข Package == Formula == ruby file โ€ข installed into /usr/local/Cellar/<package> with symlinks into /usr/local/bin, /usr/local/lib etc โ€ข Taps == Github repositories โ€ข Homebrew Core Repo Formulae โ€ข downloaded to /usr/local/Homebrew/Library/taps/homebrew/homebrew- core/formula โ€ข Bottle == binary program already built for macOS (configure and make already done for you) โ€ข Cask == GUI program or font ie microsoft-office, intellij-idea
  • 13. Homebrew โ€ข brew install <package> โ€ข brew ls โ€ข brew rm <package> โ€ข brew search <package> โ€ข brew cleanup โ€ข brew update โ€ข brew upgrade โ€ข brew cask install <gui-package> โ€ข Brew cask rm <gui-package> (removes .app from /Applications) โ€ข brew cask zap <gui-package> (like brew cask rm but also removes all preferences files etc ie full deinstallation) โ€ข brew cask rm <gui>
  • 15. Package Managers โ€ข Linux โ€ข Debian based = Debian, Ubuntu, Mint, Raspbian, Kali โ€ข Dpkg, apt, aptitude โ€ข RPM based = Red Hat, Fedora, CentOS โ€ข Rpm, yum
  • 16. Apt โ€ข sudo apt-get install <package> โ€ข sudo apt-cache search <package> โ€ข sudo apt-get purge <package> โ€ข dpkg โ€“l = list all installed packages โ€ข dpkg โ€“L <package> = show files for this package โ€ข sudo apt-get update โ€ข sudo apt-get upgrade
  • 17. Tmux โ€ข Terminal Multiplexer โ€ข brew install tmux โ€ข sudo apt-get install tmux
  • 22. Tmux Commands โ€ข tmux = start server โ€ข tmux new-session โ€“t <session-name> โ€ข tmux new-window โ€“t <window-name> โ€ข tmux split-window = horizontal split pane โ€ข tmux list-sessions (tmux ls) = list sessions โ€ข tmux list-windows โ€ข tmux list-panes
  • 23. Tmux Commands โ€ข tmux attach โ€“t <session-name> โ€ข tmux kill-session [โ€“t <session-name>] โ€ข tmux kill-window [โ€“t <window-name>] โ€ข tmux kill-pane [โ€“t <pane>]
  • 25. Inside ofTmux โ€ข Prefix = defaults to ^B (Control B) but can be changed โ€ข <prefix> + % => vertical split โ€ข <prefix> + โ€œ = horizontal split โ€ข <prefix> + c = new window โ€ข <prefix> + n = next window โ€ข <prefix> + p = previous window โ€ข <prefix> + : => command line inside tmux similar to vim โ€ข <prefix> + : then kill-pane = kills current pane โ€ข === tmux kill-pane
  • 26. ~/.tmux.conf โ€ข Prefix = defaults to control b but can be changed โ€ข These lines bind: โ€ข prefix to ^a โ€ข <prefix> - | to split vertically โ€ข <prefix> - - to split horizontally
  • 28. Tmux scripts โ€ข usually located in ~/.tmux directory โ€ข list of tmux commands to run โ€ข could be run as tmux selectp โ€“t 0 or <prefix>+: selectp โ€“t 0 โ€ข ~/.tmux/four-panes โ€ข ~/.tmux.conf
  • 31. Htop โ€ข brew install htop โ€ข sudo apt-get install htop โ€ข Similar to top but shows core usages โ€ข / to search โ€ข space to tag process โ€ข k to kill process
  • 33. ccze โ€ข brew install ccze โ€ข sudo apt-get install ccze โ€ข tail โ€“f /var/log/**/*.log | ccze โ€ข sudo id = shows up in /var/log/system.log on Mac and /var/log/auth.log on Linux
  • 34. Logging with color bash script
  • 36. iftop โ€ข brew install iftop โ€ข sudo apt-get install iftop โ€ข sudo iftop โ€“c ~/.iftop.conf โ€ข while running: โ€ข t = toggle bar display modes โ€ข q = quit โ€ข f = filter โ€ข h = help
  • 38. iftop - colorized โ€ข git clone https://github.com/MenkeTechnologies/iftopcolor โ€ข ./configure && make โ€ข sudo make install or move executable ./iftop to somewhere in PATH
  • 40. grc โ€“ general colorizer โ€ข https://github.com/garabik/grc โ€ข brew install grc โ€ข sudo apt-get install grc
  • 41. grc config files โ€ข Mac: /usr/local/share/grc/conf.ls โ€ข Linux:/usr/share/grc/conf.ls โ€ข each command that will be colorized has its corresponding config file โ€ข automatic aliases โ€ข usage: grc netstat โ€ข grc โ€“c /usr/local/share/grc/conf.ls ping google.com
  • 42. Automatic Aliasing (Over aliases) โ€ข curl https://raw.githubusercontent.com/garabik/grc/master/grc.zsh - O $HOME/grc.zsh โ€ข ~/.zshrc : [[ -s โ€$HOME/grc.zsh" ]] && source โ€œ$HOME/grc.zshโ€ โ€ข ping is now alias for grc ping
  • 43. grc uses regex for colorization
  • 44. grc demo โ€ข ping โ€ข ifconfig โ€ข dd โ€ข ps
  • 45. Python programs โ€ข Glances = pip package โ€ข Powerline status = pip package โ€ข brew install python = goes into /usr/local/Cellar/python/<version-number> โ€ข pip, package manager for python, should be included โ€ข Mac: pip installs packages to /usr/local/lib/python2.7/site- packages on โ€ข Debian: pip installs packages to /usr/local/lib/python2.7/dist- packages
  • 47. pip โ€ข pip install <package> โ€ข pip show <package> โ€ข for package in $(pip list โ€“outdated);do pip install $package done
  • 48. Powerline โ€ข Status bars for vim, tmux โ€ข requires special fonts for triangles such as Nerd Fonts โ€ข https://github.com/ryanoasis/nerd-fonts โ€ข pip install powerline-status โ€ข ~/.tmux.conf โ€ข ~/.vimrc
  • 49. Powerline forVim โ€ข recommend to install latest vim 8+ โ€ข brew install vim โ€ข sudo apt-get install vim โ€ข brew install macvim (fastest for mac IMO) โ€ข mvim โ€“v <file> = stay in terminal โ€ข mvim <file> = launch gui
  • 52. PowerlineTmux Status Bar โ€ข http://powerline.readthedocs.io/en/master/usage/other.h tml#tmux-statusline โ€ข Define tmux status line in JSON file => โ€ข $HOME/.config/powerline/themes/tmux
  • 54. My Prompt == Powerlevel 9k โ€ข https://github.com/bhilburn/power level9k โ€ข using Knack Nerd Font โ€ข brew tap caskroom/fonts โ€ข brew cask install font-hacknerd- font
  • 57. glances โ€ข pip install glances โ€ข on Mac installs to /usr/local/lib/python2.7/site- packages/glances โ€ข Debian installs to /usr/local/lib/python2.7/dist-packages โ€ข https://github.com/nicolargo/glances
  • 58. glances โ€ข sudo glances [--disable-alert] [--disable-network] [โ€ฆ] โ€ข To change text color from white to blue: โ€ข Change line 203 in glances/outputs/glances_curses.py โ€ข curses.init_pair(1, curses.COLOR_WHITE, -1)=> โ€ข curses.init_pair(1, curses.COLOR_BLUE, -1)
  • 60. Oh-my-zsh โ€ข Framework for zsh, geared toward developers โ€ข Tons of prompts and plugins โ€ข https://github.com/robbyrussell/oh-my-zsh
  • 61. Oh my zsh install โ€ข sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my- zsh/master/tools/install.sh)โ€
  • 62. Oh my zsh Plugins โ€ข git clone into ~/.oh-my-zsh/custom/plugins โ€ข add to plugins array ~/.zshrc
  • 63. Zsh-autosuggestions โ€ข copy of FISH (friendly interactive shell)โ€™s suggestions โ€ข Searches history (~/.zsh-history) for most recent commands starting with letters typed โ€ข hit right arrow to complete the suggestion โ€ข git clone https://github.com/zsh-users/zsh-autosuggestions $ZSH_CUSTOM/plugins/zsh-autosuggestions โ€ข add to plugins array in ~/.zshrc
  • 64. Zsh-syntax highlighting โ€ข Red if invalid command, green if found in PATH โ€ข highlighting for quotes โ€ข git clone https://github.com/zsh-users/zsh-syntax- highlighting.git ${ZSH_CUSTOM:-~/.oh-my- zsh/custom}/plugins/zsh-syntax-highlighting โ€ข add to plugins array in ~/.zshrc
  • 65. Zsh-completions โ€ข adds zsh completions for more commands โ€ข Adds zsh tab completions for many more commands such as caffeinate โ€ข git clone https://github.com/zsh-users/zsh-completions ~/.oh-my- zsh/custom/plugins/zsh-completions โ€ข add to plugins array in ~/.zshrc
  • 67. z command โ€ข creates database of visited directories โ€ข usage: z <directory-name> โ€ข directory-name can be just a few letters of the name โ€ข if there is a match you will cd to that directory otherwise no cd and returns 1
  • 68. z install โ€ข git clone https://raw.githubusercontent.com/rupa/z/master/z.sh $HOME โ€ข source ~/z.sh
  • 69. Zle line editor in ~/.zshrc 3) declare zsh function as widget 4) Bind widget function to Control-S key combination 1) Define zsh function 2) Define zsh function to be bound as widget. Calls above function with the contents of current command line as argument Type your commit message at prompt no quotes needed and then pressControl-S to add, commit and push to remote
  • 70. z and ZLE demo