Howtos

From ZENotes
(Difference between revisions)
Jump to: navigation, search
(GoButton adding new files to your show)
(GoButton: adding new files to your show)
Line 80: Line 80:
 
In GoButton, hit the "edit" button upper right, then the "+" ; add your desired "HIT" (not "cue", max 92 alas) ; add using the "add" button top right.  
 
In GoButton, hit the "edit" button upper right, then the "+" ; add your desired "HIT" (not "cue", max 92 alas) ; add using the "add" button top right.  
  
 
+
- Adjust the starting point by long-press, then sliding the leftmost side of the frame around the visualizer at the top. Zoom with pinch movement if necessary
- Adjust the starting point by long-press, then sliding the leftmost side of the frame around the visualizer at the top
+
  
 
- Edit the name to something more readable quickly if needed
 
- Edit the name to something more readable quickly if needed

Revision as of 12:33, 6 May 2022

these are more recipes, or even just sample of CLI that works in real life. daughter machine : Model T440s Type 20AR serial PC00L2HW[1] , 8G Ram (4G Soldered) 500G sHDD, Transcend 256Go SATA III 6Gb/s MTS430S 42 mm M.2 SSD 430S SSD TS256GMTS430S (instead of 3G Sim transmitter)

Current machine L460. It's slower than my T420s

Contents

Full YT to GoButton gymnastics

Prep work

Install youtube-dl if needed with, for Maryam's (ubuntu version of yt-dl is years late, doesn't work):

 sudo apt update
 sudo pip3 install youtube-dl

The regular line for youtube-dl, uncompressed wav format and compressed mp3 is :

 $ youtube-dl -x --audio-quality 0 --audio-format wav https://youtu.be/<yt code of video as found in title>
 $ youtube-dl -x --audio-quality 2 --audio-format mp3 https://youtu.be/<yt code of video as found in title>

Let's make some .bashrc alias :

Add anywhere near other "alias xx="xx -xx" the following for .wav, or MP3 in the .bashrc file, using nano or gedit :

 alias getthatwav='youtube-dl -x --audio-quality 0 --audio-format wav'
 alias getthatmp3='youtube-dl -x --audio-quality 2 --audio-format mp3'

I would also do a simpler version :

 alias getwav='youtube-dl -x --audio-quality 0 --audio-format wav'
 alias getmp3='youtube-dl -x --audio-quality 2 --audio-format mp3'

Actual transfers

Download the sound from any YT video : Open terminal, like hit "meta" key and start typing "term" ; input the following :

 cd Musique [ENTER]
 getthatwav <full youtube address of file as copypasted from the adrress bar of the browser> [ENTER]

! Don't forget about the [TAB] autocompletion trick, and the [UP ARROW] find-me-latest-commands trick !

OR, if the video is very long and you don't want to choke your hard drive and your transfer times, use mp3 compression :

 getthatmp3 <youtube address of file> [ENTER]

You can use the middle click to paste into the terminal or Shift+Crtl+V (instead of the usual Shift+V) to paste the copied address


So your IRL process is like this :

 Open Firefox, go to YT, find some zique
 Open Terminal, move to the appropriate Musique directory by typing cd Musique [ENTER]
 * in Firefox triple-click to highlight youtube address in browser address bar
 * in Terminal, type getthatw [TAB], middle click next to getthatwav to paste YT address, [ENTER]
 or
 * in Terminal, type getthatm [TAB], middle click next to getthatmp3 to paste YT address, [ENTER]
 

That's it :)


Recommend you rename the files on the PC, it's easier than on the pad (but doing so you loose the source of your file since youtube-dl save the full title and youtube code of the ripped piece in its name).

On the Pad :

1. Make sure pad and laptop are on the same wifi network (can totally be your phone's Hotspot)

2. Open VLC, go to "résaux", hit "partage via WiFi", notice the IP "http://xxx.xxx.xxx.xxx" address, it's your iPad address on the local network.

3. in Firefox, open new tab and input same IP address, or even just try "ipad.local"

4. Paste using the big fat "+" button upper right corner

5. Using the File Manager, move new files from vlc to the GoButton folder, possibly there in yet another, specific folder for better organisation

GoButton: adding new files to your show

In GoButton, hit the "edit" button upper right, then the "+" ; add your desired "HIT" (not "cue", max 92 alas) ; add using the "add" button top right.

- Adjust the starting point by long-press, then sliding the leftmost side of the frame around the visualizer at the top. Zoom with pinch movement if necessary

- Edit the name to something more readable quickly if needed

- Choose appropriate color, like "sound effect", "mood music" etc

- Check volume using the green [Preview] button and adjust if necessary

- Adjust the "stop others" rule : for musics, use [hits & cues] with fade out time of i.e. 3 seconds unless you need differently depending on thhe start of the music interrupting the others. For sound effects, don't do this since you may want several effects running at the same time, including over the music.

- Adjust "loop" properties if you need the sound to last longer / to be able to cover an entire act using either [FIXED] value of repetition or [INFINITE]

- - Adjust the end point too if you are using the loop function !

- You can add a keyboard shortcut using the [Triggers] function, select "keyboard" and your shortcut key

- Don't forget to [SAVE] your editions upper right !

- Hit [DONE] when done to go back to playback mode


When your show is ready, organised, re-listen to all of them to be sure musics are somewhat equal, and sound effects can mix & live with them nicely.

Notes

After a few minutes without using it, VLC will close the connection, this is normal.

You need to stay on the vlc share page, or the sharing thing will shut itself down.

Downloading from YT is a moving target, it's normal and expected it will stop working at some point; first thing to do is updating youtube-dl

sudo pip install -U youtube-dl

Your source of copyright-free sound effects is https://pixabay.com/sound-effects AVOID YOUTUBE when you can, pixabay also has music :)

Mount nfs

From Nautilus

 nfs://192.168.xxx.xxx:0/<Share to mount>

or...

 nfs://192.168.xxx.xxx:/<Share to mount>

from the 'other locations' tab in Nautilus.

From Terminal

# mount 192.168.xxx.xxx:/<share to mount> ~/<destination folder/

the -t nfs doesn't seems to be needed most of the time. Don't forget to install nfs-utils lol

Query by size

From here

du -h $(du -b * | sort -n | cut -f2-)

Scan from network

Need reportlab, hplip, python imaging library. And possibly to run hp-setup -i just to wake things up.

[jph@ThinkDMX3 ~]$ hp-scan --device='hpaio:/net/OfficeJet_7510_series?ip=<ip address without port>' --output=output.pdf

When all said and working, scan in color at 300DPI with :

hp-scan -m color --size=A4 -o /dest/of/file/NameOfFile.pdf

Boot GRUB manually when failing to locate your kernel (use tab to fill)

Check disks available:
grub> ls

define root system:
grub> root=(hd0,msdos1)

Load the kernel image:
grub> linux /boot/wmlinuz root=/dev/sda1
!! This could be, not sure, use Tab to autocomplete:
grub> linux /boot/wmlinuz-linux root=/dev/sda1

Locate initial ramdisk:
grub> initrd /boot/initramfs-linux.img

Boot the damn thing & now tell me why GRUB isn't just doing it by itself
grub> boot

Retrieved from https://www.unix-ninja.com/p/Manually_booting_the_Linux_kernel_from_GRUB

Also, upon install, don't save your grub config file as grub.conf...

Cleanup pacman's cache:

paccache -r[2]

Query both battery states

 upower -i $(upower -e | grep 'BAT1') | egrep 'BAT1|energy' & upower -i $(upower -e | grep 'BAT0') | egrep 'BAT0|energy'


Add it as alias in .basrc as

 alias BATT="upower -i $(upower -e | grep 'BAT1') | egrep 'BAT1|energy' & upower -i $(upower -e | grep 'BAT0') | egrep 'BAT0|energy'"

Needs double quotes because of the use of single quote in the command


WebDAV to ownCloud

Syntax for Nautilus access through WebDAV towards an owncloud instance :

 davs://adress.ofyour.cloud/remote.php/dav/files/nameofuser

this will prompt for a username and password and bring you to the root of the File side of things, which is useless. Your actual share is network adress / files /username, not the visibly mounted network share that ony goes to adress.ofyour.cloud/remote/dav (which shows a bunch of stuff you can't do a thing to. be sure to bookmark it the real ./files/usermane location. The system creates a username and impossible password for you, be sure to not use the generic host creds. The actual line for me is davs://tic.<myserver>.net/remote.php/dav/files/<username as generated>

Force IPV4 GPG keys renewal / finding

IF it's just "missing keys" or "invalid" or such, try :

# pacman-keys --populate archlinux

or

# pacman-key --refresh-keys 

Or the caveman way :

# pacman -S archlinux-keyring

If in yay, try this :

# gpg --keyserver keys.gnupg.net --recv-keys <insert key number here>

Or this for TOR for instance :

# gpg --auto-key-locate nodefault,wkd --locate-keys torbrowser@torproject.org

If #pacman -S archlinux-keyring fails after a global $yay -Syu aborted with some gpg keys gibberish, try this:

Fight stupid GPG keys that won't update other than over an IPV6 address :

I ran into this problem on MacOS 10.13.6, and I currently suspect it's something weird with gpg deciding to use IPv6.

I currently don't have a valid global IPv6 address, so all IPv6 addrs should be "no route to host", 
but I noticed that if I manually look up keys.gnupg.net and substitute in one of the IPv4 addresses explicitly, 
then the command works  and I can proceed, without doing the other workaround with curl.

$ gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
gpg: keyserver receive failed: No route to host
 
$ host keys.gnupg.net
keys.gnupg.net is an alias for hkps.pool.sks-keyservers.net.
hkps.pool.sks-keyservers.net has address 51.38.91.189 
[...]
hkps.pool.sks-keyservers.net has IPv6 address 2001:67c:26b4::98:0 

$ gpg --keyserver hkp://51.38.91.189 --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
gpg: key 105BD0E739499BDB: 4 signatures not checked due to missing keys
gpg: key 105BD0E739499BDB: public key "Piotr Kuczynski <piotr.kuczynski@gmail.com>" imported
gpg: key 3804BB82D39DC0E3: 101 signatures not checked due to missing keys
gpg: key 3804BB82D39DC0E3: public key "Michal Papis (RVM signing) <mpapis@gmail.com>" imported
gpg: no ultimately trusted keys found
gpg: Total number processed: 2
gpg:               imported: 2  

replace with an actual output of list of keyserver and the signed key that failed to import. Source : https://github.com/rvm/rvm/issues/4215

==> PGP keys need importing:
 -> CC0B7CE9604A8A91F0D70B778489DB248465FDD7, required by: nordselect
==> Import? [Y/n] 
:: Importing keys with gpg......
gpg: keyserver receive failed: No route to host
==> Error: Problem importing keys
[jph@ThinkDMX2 ~]$ host keys.gnupg.net
keys.gnupg.net is an alias for hkps.pool.sks-keyservers.net.
hkps.pool.sks-keyservers.net has address 192.146.137.140
[...]
[jph@ThinkDMX2 ~]$ gpg --keyserver hkp://192.146.137.140 --recv-keys CC0B7CE9604A8A91F0D70B778489DB248465FDD7
gpg: key 8489DB248465FDD7: public key "Ward Segers <w@rdsegers.be>" imported
gpg: Total number processed: 1
gpg:               imported: 1
[jph@ThinkDMX2 ~]$ yay nordvpn

Add a user to a group:

sudo gpasswd -a <user> <group>

or

sudo usermod -aG <group> <user>

make a sudo command works without password in sudoers file

$USERNAME ALL=NOPASSWD:/path/to/app

wget-ftp the fuck out of our public server:

wget -cr ftp://username:password@ftp.provider.org//www/singapore/galleries


find UUID of a partition:

ls /dev/disk/by-uuid -l


Possibly outdated

Enable Tap To Click

  synclient TapButton1=1

Enable Tap-To-Click on that Red 'nipple' Button. You know you want to

  su -c 'echo -n 1 >  /sys/devices/platform/i8042/serio1/serio2/press_to_select'  


Check that hard drive for space-eating goblins:

sudo du / -ch -d 1|grep G


When you can't read your console font

setfont sun12x22

Touchpad: increasing the pressure necessary to register touch.

 synclient FingerHigh=110 FingerLow=100


Control your brightness.

...Well, not yours actually, sorry I can't do that.

xbacklight -inc 5 or xbacklight -dec 5


Get natural scrolling in i3:

xinput set-button-map 12 1 2 3 5 4 6 7 8 9 10 11 12
My bashrc alias is  alias natscroll='xinput set-button-map 12 1 2 3 5 4 6 7 8 9 10 11 12 

Want to know what's the keycode to that obscure symbol on your keyboard? Use xev


Test the 6 channels output of a Terratec Aureon 5.1 MkII USB soundcard

speaker-test -Dsurround51:CARD=Aureon51MkII,DEV=0 -c 6


Convert !

All .mp3's in a folder to .wav to be able to work on them:

for i in *.mp3; do mpg321 -w "`basename "$i" .mp3`".wav "$i"; done


Convert all .m4a's in a folder to .wav to be able to work on them:

for i in *.m4a; do faad -o "`basename "$i" .m4a`".wav "$i"; done


Convert .ai in a folder to .wav to be able to work on them:

sox <file>.aif file.wav


Random Whatever:

Listen to France Inter or other radios :

mplayer http://direct.franceinter.fr/live/franceinter-midfi.mp3

This seems good on X1 : https://push.cx/2015/dual-booting-arch-linux-on-lenovo-x1-carbon-3rd-gen

Try to get a flick from your computer to a DVD

Dump the Firefox history sql file

Start X when Log in occurs

Running another X session somewhere else.

The Short Dirty Kernel DIY

Mount mtp devices

Remember AlsaMixer settings

I love Grub1 (Grub 'legacy' now)

A word on SLIM

Use curl to tweet.

Using the CLI to burn an .iso cd.

find stuff.

ffmpeg to convert videos for my phone.

Allow sudo to open up a graphic application as loan modification root from your normal user account or from a root terminal in your normal user account

remount a ro filesystem rw: mount -o remount,rw so that when the system drops you to a shell on boot failure, YOU CAN DO SOMETHING FOR FUCK'S SAKE! And no, it is not in man 8 mount, it isn't.

Connect remotely to a VirtualMachine - how arch-cool is that?

Simple rsync line that works here

MPlayer code to listen to France Inter and other radios, Now, radiotray is cool too.

MPlayer code to watch my QuickCam Communicate STX Webcam See Syntek readme first for stk webcams.

A healthy, fast image gallery starts with reasonably-sized pictures: thanks imagemagick!

Cool ssh

vnc is flawless in Fedora :)

throttling the cpu - mixed results, if for battery life.

Custom Bash - Some Terminal Fun

Calculating Pi

Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox