Skip to content

Instantly share code, notes, and snippets.

@gladx
Last active September 19, 2017 06:46
Show Gist options
  • Save gladx/685aab3a31b891a27f96fff26c91c79b to your computer and use it in GitHub Desktop.
Save gladx/685aab3a31b891a27f96fff26c91c79b to your computer and use it in GitHub Desktop.
sudo passwd username
------------------- hardware info
Battery Info
upower -i /org/freedesktop/UPower/devices/battery_BAT0
acpi -V
less a.txt less is show text file faster than vim or more
more a.txt text editor ?
------------------
how copy folder with content
cp -R copy folder with sub folder and files
cp -v veiw proccess
----------------
[ls]
ls : list of file
-a all with . & ..
-l print the author of each file
-b print name withe nongraphic characters
-h with -l list human readable size
-X sort by alphbatically
---------------------------------------------
my
youtube-dl -a list2 -g |grep "" >down
-a bach file
-g link download
|gerp output formating
"" pattern
>down file save info from gerp
youtube-dl -f bestvideo+bestaudio "link to youtube video"
youtube-dl -f 'bestvideo[ext=mp4]+bestaudio[ext=m4a]/bestvideo+bestaudio' --merge-output-format mp4 "link to youtube video"
-----------------------
export https_proxy='http://localhost:8080'
set proxy
----------------
[find]
find : find file
find /home/ -name "*.mp3"
find /home/ -mame "*file_name*"
------------
[ls tab ]
lsusb list of usb
lspci list of pci device
lshw list hardware
lsblk - list block devices
ls list
-------------
sudo
sudo : run root user command
-s chenge user to super user
exit exit from super user
exit exit from terminal
------------
run background app
$ firefox &
back ro for ground
jobs veiw app background
fg %1
----------
math calculate
echo $[5*6]
----------
uptime
w
top : list of process
----------
sudo service mysql start
sudo service mysql stop
-----------
show ascii code
showkey -a
exit ctrl-d
Quastion : ctrl-Enter 10
Enter 13 why?
----------
how to create zip file of folder?
Create archive.tar from files foo and bar.
tar -cf archive.tar foo bar
List all files in archive.tar verbosely.
tar -tvf archive.tar
Extract all files from archive.tar.
tar -xf archive.tar
-----------
convert File*.jpg All.pdf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment