Skip to content

Instantly share code, notes, and snippets.

prefix=/home/username/.npm_globals
https-proxy=http://proxy-host:proxyport/
proxy=http://proxy-host:proxy-port
@t-chab
t-chab / retroarch.cfg
Last active December 31, 2016 09:46
Retroarch setup utility script and config files
config_save_on_exit = "true"
input_max_users = "15"
input_menu_toggle_gamepad_combo = "0"
input_axis_threshold = "0.500000"
ui_companion_start_on_boot = "true"
video_gpu_record = "false"
input_remap_binds_enable = "true"
back_as_menu_toggle_enable = "true"
netplay_client_swap_input = "true"
input_descriptor_label_show = "true"
@t-chab
t-chab / TVHeadend frequencies.md
Last active May 8, 2018 14:39
TVHeadend french frequencies for Toulouse city

Here's the french DVB-T Multiplex frequencies for using with Tvheadend software in Toulouse city.

In Tvheadend, go to Configuration tab, DVB Inputs, then Muxes. Click on Add button, choose network, then set the frequency to one of the values below, set Bandwidth to 8Mhz, and everything else to AUTO

  • R1 : 506.166 Mhz (25H - 3.3kW)
  • R2 : 610.166 Mhz (38H - 4kW)
  • R3 : 498.166 Mhz (24H - 4kW)
  • R4 : 522.166 Mhz (27H - 3.2kW)
  • R5 : 506.166 Mhz stopped on April, 5th 2016
  • R6 : 594.166 Mhz (36H - 3.6kW)
smbclient -N //IP.OF.SAMBA.SERVER/sharedFolder/ -U% -c ls
@t-chab
t-chab / update.sh
Last active August 29, 2015 14:24
Simple shell script to rebuild and upgrade AUR packages
#!/usr/bin/env bash
PKG_LIST=$(pacman -Qm |awk '{ print $1}' |tr '\n' ' ')
WORK_DIR="$(mktemp -d)"
for i in $PKG_LIST
do
echo "Building package $i in $WORK_DIR/$i"
cd $WORK_DIR
prefix=$(echo ${i:0:2})
@t-chab
t-chab / options.sh
Created July 7, 2015 13:12
Java JMX remote monitoring JVM option
export JAVA_OPTS="-Dcom.sun.management.jmxremote.authenticate=false\
-Dcom.sun.management.jmxremote.port=XXXX\
-Dcom.sun.management.jmxremote=true\
-Dcom.sun.management.jmxremote.ssl=false"
@t-chab
t-chab / Dockerfile
Last active January 12, 2022 18:31
telegram-bot Dockerfile, with youtube download plugin
FROM debian:latest
MAINTAINER [email protected]
# install app
#############
# install app from official repos, set perms, cleanup
# User telegramd is added manually to force uid to 5000, to avoid perms problems
RUN groupadd -r -g 5000 telegramd && \
set-option -g lock-command "vlock"
unbind ^X
bind ^X lock-server
unbind x
bind x lock-server
@t-chab
t-chab / http-reverse-proxy.conf
Created November 18, 2014 16:24
Apache reverse proxy sample configuration
ServerRoot "/opt/httpd-proxy"
LoadModule alias_module modules/mod_alias.so
LoadModule authz_host_module modules/mod_authz_host.so
LoadModule headers_module modules/mod_headers.so
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule proxy_connect_module modules/mod_proxy_connect.so
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule log_config_module modules/mod_log_config.so
@t-chab
t-chab / temp.sh
Created November 18, 2014 05:54
Shell script which log temperature to a temp file
#!/usr/bin/env sh
# sensors, hddtemp and nvidia-smi commands should be in path
CORE0_TEMP=$(sensors | grep 'Core 0' | awk -F':' '{print $2}' | awk -F'(' '{print $1}' |tr -d ' +')
CORE1_TEMP=$(sensors | grep 'Core 1' | awk -F':' '{print $2}' | awk -F'(' '{print $1}' |tr -d ' +')
HDD_TEMP=$(hddtemp /dev/sdb |awk '{ print $3}')
GPU_TEMP=$(nvidia-smi -a |grep "GPU Current Temp" |awk '{ print $5}')
OUT_FILE=/tmp/$(date +%Y-%m-%d).temp.log