Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- informação sobre o SO instalado
- cat /etc/lsb-release
- sudo blkid -s UUID
- Montar Sd Card
- # modprobe mmc_block
- # modprobe wbsd
- sudo modprobe tifm_sd
- lsblk
- sudo lsblk -o MODEL,NAME,FSTYPE,LABEL,MOUNTPOINT,SIZE
- sudo modprobe ohci_hcd
- =========================================================================================================
- Ativar e sesativar Touchpad
- synclient TouchpadOff=1
- synclient TouchpadOff=0
- =========================================================================================================
- sudo fdisk -l
- sudo mount /dev/sda1 /mnt
- sudo grub-install --root-directory=/mnt /dev/sda
- ------------------------------------
- sudo aptitude update
- sudo aptitude install xxxxx
- sudo dpkg -i --force-overwrite /var/cache/apt/archives/libjack0_0.118+svn3796-1ubuntu2_i386.deb
- sudo grub-install --recheck /dev/sdc
- sudo apt-get remove grub
- sudo apt-get install grub /dev/sda
- sudo update-grub
- sudo add-apt-repository ppa:danielrichter2007/grub-customizer
- sudo apt-get update
- sudo apt-get install grub-customizer
- =========================================================================================================
- clone bootable USB stick
- Plug in both USB pen drives and type: fdisk -l as root in terminal to see what their device names are.
- If they appear as /dev/sdb and /dev/sdc, type in a terminal: dd if=/dev/sdb of=/dev/sdc conv=notrunc.
- To make an image of the entire drive including MBR (boot files),
- type in terminal:
- dd if=/dev/sdb of=/path/to/destination/image.dd conv=notrunc.
- To restore the image to a new drive which is seen as /dev/sdb:
- dd if=/path/to/image.dd of=/dev/sdb conv=notrunc
- dd if=/dev/<device1> of=/dev/<device2>
- dd if=/dev/random of=/dev/null bs=1K count=100
- (pv -n /dev/sda | dd of=/dev/sdb bs=128M conv=notrunc,noerror) 2>&1 | dialog --gauge "Running dd command (cloning), please wait..." 10 70 0
- sudo apt-get install pv dialog
- dd if=/dev/urandom | pv | dd of=/dev/null
- ==========================================================================================================
- Resize fotos
- mogrify -resize 800x600 -format jpg *
- ==========================================================================================================
- Restart KDE without rebooting the computer
- Save and close all open applications.
- Use the Ctrl-Alt-Backspace shortcut keys to restart KDE.
- If Ctrl-Alt-Backspace is disabled, type
- sudo /etc/init.d/kdm restart
- ==========================================================================================================
- mplayer -vo fbdev -fs Japmagic.mpg
- mplayer -vo svga -ao sdl Japmagic.mpg
- ==========================================================================================================
- #sudo mke2fs -t ext3 -L multiboot /dev/sdb1
- #sudo mkdir /media/pendrive
- #sudo mount /dev/sdb1 /media/pendrive
- #sudo grub-install --force --no-floppy --root-directory=/media/pendrive /dev/sdb
- #sudo grub-mkconfig -o /media/pendrive/boot/grub/grub.cfg
- ==========================================================================================================
- normalize -m -V musica.mp3
- ==========================================================================================================
- Listagem de tudo
- ls -R | grep "." > texto.txt
- ==========================================================================================================
- Retirar vocal
- install mplayer lame shntool
- mplayer -ao pcm:file=<output file> -af karaoke <input file (song)>
- lame -V2 <input wav file> <output mp3 file>
- Special Effects
- There is good support for audio effects, and the karaoke effect especially gets interesting with certain songs. It is not perfect, but you can attenuate the voice in a song a great deal. Use the following command to activate karaoke mode:
- $ mplayer -af karaoke song.mp3
- MPlayer also has a ten-octave band equalizer. The following command ignores the middle frequency bands and amplifies the frequencies around 31.25Hz by 7dB, 62.5Hz by 8dB, 125Hz by 5dB and all of the frequencies around 4, 8 and 16Hz are attenuated by 2dB:
- $ mplayer -af equalizer=7:8:5:0:0:0:-2:-2:-2 video.mpg
- The following command gives a live effect to playback. Try it with songs that sound monotonous:
- $ mplayer -af extrastereo song.mp3
- You can issue a command like the following to play the third song five times:
- $ mplayer song1.mp3 song2.ogg file.wav -loop 5
- If you want to repeat the whole list five times, type the following instead:
- $ mplayer { song1.mp3 song2.ogg file.wav } -loop 5
- You also can use -loop 0 to play something over and over again.
- Additionally, there are many audio effect plugins designed especially for multichannel and 3-D audio. If you want some really advanced audio effects, try the SoX Swiss Army knife. It is another command-line application that excels in professional audio effects.
- You can specify multiple audio filters on the command line and they are applied one after another in a chain.
- What if you like a certain audio filter chain and you want to save the resulting audio to a file? The following command saves the output of filtering to the file named filtered.wav rather than playing it:
- $ mplayer -ao pcm:file=filtered.wav -channels 4 -af
- lavcresample=48000,hrtf,pan=2:1:0:0:0.3:0.5:0.5:0:12 audio.ogg
- The lavcresample filter resamples the frequency of audio.ogg to 48,000Hz.
- The pan filter is a very powerful and sophisticated filter. It mixes the input audio channels into the specified output channels in various amplitudes.
- In this example, we use the -channels switch to specify four input channels. The first argument to pan is 2 to specify two output channels. In the first pair of arguments after that, the 1:0 specifies the amplitude of the first input channel that is fed into the two output channels. It goes into the left channel with an amplification factor of 1. The second input channel goes into the right channel with an amplification factor of 0.3 (0:0.3), and the third input channel is divided equally into both output channels (0.5:0.5). The fourth channel goes into the right channel with an amplification factor of 12.
- You can use the following command to re-encode the WAV file to Ogg:
- Get ffmpeg, dvdauthor, dvdstyler installed on your system, then you can:
- Code:
- ffmpeg -i source.avi -target ntsc-dvd target.mpg
- and either do this to make a simple DVD:
- Code:
- dvdauthor -t -o target.dvd -f target.mpg
- dvdauthor -T -o target.dvd
- or use dvdstyler to create a basic menu structure.
- man ffmpeg for more options on creating your .mpg files.
- ==========================================================================================================
- mencoder arquivo.avi -of mpeg -oac mp3lame -ovc lavc -lavcopts vcodec=msmpeg4:vbitrate -vf lavcdeint,scale -zoom -xy 352 -o arquivo.mpg
- $ oggenc -q 9 filtered.wav
- ==========================================================================================================
- Baixar video no youtube
- youtube-dl -F url
- youtube-dl -cwt -f 22 url
- ==========================================================================================================
- Apagar arquivos
- find / -iname nome-do-arquivo.txt -exec rm -f '{}' \;
- ==========================================================================================================
- Converter PDF to JPG
- Basically:
- Code:
- convert -geometry 600 -quality 90 -myfile.pdf myfile.jpg
- or enhance it with:
- Code:
- convert -geometry 600 -quality 90 -unsharp 0.7x1.1+2.0+0 nhk.pdf nhk.jpg
- 600 pixels is pretty small. With this conversion I converted a pdf document in 10pt font, and it is perfectly legible.
- Convert is a part of the ImageMagick suite.
- Additonally, you could cut the margins off the sides while converting. Showing white margins does add to the size, but not to the information. It is done with ImageMagick convert as well.
- convert -geometry 800 -shave 100x0 -quality 90 myfile.pdf myfile.jpg
- This will first convert the picture to a width of 800 px, and then shave 100 px off at each side
- I think, I have now the parameters for the best output from my pdf-files:
- -----------
- convert -trim -posterize 9 +matte -geometry 650 -linewidth 1 -identify -enhance +dither -colors 16 +contrast +contrast -density 88 -black-point-compensation -quality 100 -unsharp 0.7x1.1+2.0+0 2.pdf 2.jpg
- -----------
- very helpful parameters:
- -trim: crops white margins
- -geometry: works perfectly
- -colors 16: I don't need all colors, because I have only text in tables
- ===========================================================================================================================================================
- Criar a imagem do HD de origem e armazená-lo no HD externo:
- # dd if=/dev/sda conv=sync,noerror bs=64K > /mnt/sda.img
- Para recuperar a imagem:
- # dd if=/mnt/sda.img of=/dev/sda conv=sync,noerror bs=64k
- Clonar o HD físico em /dev/sda para o outro hd físico em /dev/sdb:
- dd if=/dev/sda of=/dev/sdb bs=4096 conv=notrunc,noerror
- dd if=/dev/hda6 of=/dev/hda6/backup.iso
- $ dd if=/dev/sr0 of=archbang-2011.11-i686.iso
- sudo dd if=archbang-2011.11-i686.iso of=/dev/sdd bs=8MB
- ===========================================================================================================================================================
- Converter e splitar flac em mp3lame
- shntool split <yourflacfile> -f <yourcuefile> -t '%n - %t' -o 'cust ext=mp3 lame --quiet -V 2 --vbr-new - %f'
- cuebreakpoints cue | shnsplit -o flac The\ Donnas\ -\ Gold\ Medal\ \(japanese\ edition\)\ \(2004\).flac
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement