Skip to content

Instantly share code, notes, and snippets.

View yoshi314's full-sized avatar

Marcin Kowalski yoshi314

  • PL
View GitHub Profile
@rogeliodh
rogeliodh / custom.sh
Last active February 12, 2019 09:42
[x1ii] custom script to extract some info from x1ii
#!/bin/sh
SD=/mnt/mmc/debug
mkdir -p "$SD"
main() {
sleep 3
/bin/mount
/bin/dmesg
ls -lR /proc/
@rogeliodh
rogeliodh / mmc.sh
Created January 20, 2017 22:34
[X1ii] Replacement mmc.sh to run [sdcard]/custom.sh script on boot [tested with FW < 1.5.6]
#!/bin/sh
if [ "$ACTION" == "add" ]
then
echo add > /tmp/mmc_add
/bin/mount -t vfat -o iocharset=utf8,shortname=mixed /dev/$1 /mnt/mmc
if [ "$?" != "0" ]
then
/bin/mount -o iocharset=utf8 /dev/$1 /mnt/mmc
fi
@rogeliodh
rogeliodh / x1ii_fw_unpack.sh
Created January 20, 2017 22:31
script to unpack Fiio's X1ii firmware files
#!/bin/sh
set -e
mkdir -p myfw
tar zxvf X1II.fw -C myfw
# unyaffs2 from yaffs2utils is not working
#sudo ./unyaffs2 myfw/fifo_rootfs.yaffs2 myfw/fifo_rootfs
# Use unyaffs from ubuntu's unyaffs package (apt-get install unyaffs)
sudo unyaffs myfw/fifo_rootfs.yaffs2 myfw/fifo_rootfs
@bastman
bastman / docker-cleanup-resources.md
Created March 31, 2016 05:55
docker cleanup guide: containers, images, volumes, networks

Docker - How to cleanup (unused) resources

Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...

delete volumes

// see: https://github.com/chadoe/docker-cleanup-volumes

$ docker volume rm $(docker volume ls -qf dangling=true)

$ docker volume ls -qf dangling=true | xargs -r docker volume rm

@bpierre
bpierre / README.md
Last active February 15, 2024 18:40
Switch To Vim For Good

Switch To Vim For Good

NOTE: This guide has moved to https://github.com/bpierre/switch-to-vim-for-good

This guide is coming from an email I used to send to newcomers to Vim. It is not intended to be a complete guide, it is about how I switched myself.

My decision to switch to Vim has been made a long time ago. Coming from TextMate 1, I wanted to learn an editor that is Open Source (so I don’t lose my time learning a tool that can be killed), cross platform (so I can use it everywhere), and powerful enough (so I won’t regret TextMate). For these reasons, Vim has always been the editor I wanted to learn, but it took me several years before I did it in a way that works for me. I tried to switch progressively, using the Janus Vim distribution for a few months, then got back to using TextMate 2 for a time, waiting for the next attempt… here is what finally worked for me.

Original gist with comments: https://gist.github.com/bpierre/0a0025d348b6001394e0

@gdvalle
gdvalle / putty-monokai.reg
Created December 2, 2012 05:24
Monokai style theme for PuTTY; colors copied from ST2's theme
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\SimonTatham\PuTTY\Sessions\monokai]
"Colour21"="255,255,255"
"Colour20"="245,222,179"
"Colour19"="200,240,240"
"Colour18"="0,217,217"
"Colour17"="179,146,239"
"Colour16"="174,129,255"
"Colour15"="122,204,218"