Commit before pull and merge.

This commit is contained in:
Cyteen 2019-03-25 10:45:38 +00:00
parent 473ea7245a
commit c37797b489
21 changed files with 664 additions and 52 deletions

BIN
.020_pycharm-install.sh.swp Normal file

Binary file not shown.

View File

@ -8,8 +8,9 @@ AVAILABLE=/etc/apt/sources.list-available
mkdir -p "${AVAILABLE}"
SECTION=(main contrib non-free)
ACTIVE_LIST=('ascii' 'ascii-security' 'ascii-updates' 'ascii-backports')
INACTIVE_LIST=('jessie' 'jessie-security' 'jessie-updates' 'jessie-backports' 'beowulf' 'beowulf-security' 'beowulf-updates' 'beowulf-backports' 'ceres')
ACTIVE_LIST=('ascii' 'ascii-security' 'ascii-proposed-security' 'ascii-updates' 'ascii-backports' 'ascii-proposed')
#ACTIVE_LIST=('beowulf' 'beowulf-security' 'beowulf-proposed-security' 'beowulf-updates' 'beowulf-backports' 'beowulf-proposed')
INACTIVE_LIST=('jessie' 'jessie-security' 'jessie-proposed' 'jessie-updates' 'jessie-backports' 'beowulf' 'beowulf-security' 'beowulf-updates' 'beowulf-backports' 'ceres')
OTHER_LIST=('experimental')

View File

@ -16,6 +16,15 @@ ATTRS{idVendor}=="21a9", ATTRS{idProduct}=="1004", MODE="664", GROUP="plugdev"
LABEL="saleae_logic_rules_end"
EOF
cat > /etc/udev/rules.d/99-ch341a-prog.rules << 'EOF'
SUBSYSTEM!="usb", GOTO="ch431a-prog_rules_end"
ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="5512", MODE="0666", GROUP="plugdev"
LABEL="ch431a-prog_rules_end"
EOF
echo 'blacklist usbtest' >> /etc/modprobe.d/blacklist.conf
cat > /etc/udev/rules.d/99-xf2-logic.rules << 'EOF'
SUBSYSTEM!="usb", GOTO="fx2-probe--programming_rules_end"
@ -55,6 +64,22 @@ ATTRS{idVendor}=="10C4", ATTRS{idProduct}=="EA61", MODE="0666", GROUP="plugdev"
LABEL="cp210x-programming_rules_end"
EOF
cat > /etc/udev/rules.d/99-ftdi.rules << 'EOF'
SUBSYSTEM=="usb", GOTO="ftdi_rules_end"
ATTR{product}=="ftdi", ATTR{idProduct}=="0403", ATTRS{idVendor}=="6001", MODE="0666", GROUP="plugdev"
LABEL="ftdi_rules_end"
EOF
cat > /etc/udev/rules.d/99-USBasp.rules << 'EOF'
SUBSYSTEM=="usb", GOTO="USBasp_rules_end"
ATTR{product}=="USBasp", ATTR{idProduct}=="05dc", ATTRS{idVendor}=="16c0", MODE="0666", GROUP="plugdev"
LABEL="USBasp_rules_end"
EOF
cat > /etc/udev/rules.d/81-thinkpad-dock.rules << 'EOF'
KERNEL=="dock.0", ACTION=="change", RUN+="/usr/local/sbin/thinkpad-dock.sh"
EOF
@ -66,3 +91,4 @@ ATTR{idVendor}=="18d1", ATTR{idProduct}=="4ee7", MODE="0666", GROUP="plugdev", S
LABEL="android_rules_end"
EOF

View File

@ -25,6 +25,7 @@ apt-get -y install sysstat
apt-get -y install mpv
apt-get -y install youtube-dl
apt-get -y install cmus
apt-get -y install scdl
apt-get -y install checkinstall
apt-get -y install ntp ntpdate
apt-get -y install nmap

4
010_hddtemp.sh Normal file
View File

@ -0,0 +1,4 @@
apt-get install -y hddtemp
# RUN_DAEMON="false"
sed -i 's,^\(RUN_DAEMON=\).*,\1'\"true\"',' /etc/default/hddtemp

View File

@ -1,18 +1,143 @@
ARDUINO_VERSION=1.8.5
#ARDUINO_VERSION=nightly
#ARDUINO_HOME=~/
ARDUINO_HOME=/opt
ARDUINO_DIR=${ARDUINO_HOME}/arduino-${ARDUINO_VERSION}/
ARDUINO_TOOLS_DIR=${ARDUINO_TOOLS_DIR}
ADD_URLS=
cd /var/tmp
#ARDUINO_VERSION=1.8.3
ARDUINO_VERSION=nightly
mkdir "${ARDUINO_TOOLS_DIR}"
sudo apt-get install gcc-arm-none-eabi openocd bsdtar
cd /var/tmp || exit
#Install arduino IDE
wget -c https://downloads.arduino.cc/arduino-${ARDUINO_VERSION}-linux64.tar.xz && \
cd /opt && \
cd ${ARDUINO_HOME} && \
tar xf /var/tmp/arduino-${ARDUINO_VERSION}-linux64.tar.xz
usermod -a -G dialout $USER && \
usermod -a -G dialout "${USER}" && \
apt-get install git python-serial
mkdir -p ~/Arduino/hardware/espressif && \
cd ~/Arduino/hardware/espressif && \
#https://raw.githubusercontent.com/espressif/arduino-esp32/master/package/package_esp32_index.template.json
#http://arduino.esp8266.com/stable/package_esp8266com_index.json
#https://github.com/stm32duino/BoardManagerFiles/raw/master/STM32/package_stm_index.json
#https://sandeepmistry.github.io/arduino-nRF5/package_nRF5_boards_index.json
#https://micooke.github.io/package_nRF5_smartwatches_index.json
# https://github.com/arduino/Arduino/wiki/Unofficial-list-of-3rd-party-boards-support-urls
# Install ESP32 core
ADD_URLS="${ADD_URLS},https://raw.githubusercontent.com/espressif/arduino-esp32/master/package/package_esp32_index.template.json"
${ARDUINO_DIR}/arduino \
--pref boardsmanager.additional.urls=${ADD_URLS} \
--save-prefs
# arduino [--install-boards package name:platform architecture[:version]]
${ARDUINO_DIR}/arduino --install-boards esp32:esp32
mkdir -p ${ARDUINO_DIR}/hardware/espressif && \
cd ${ARDUINO_DIR}/hardware/espressif && \
git clone https://github.com/espressif/arduino-esp32.git esp32 && \
cd esp32 && \
git submodule update --init --recursive && \
cd esp32/tools/ && \
python get.py
# Install ESP8266
cd /var/tmp || exit
ADD_URLS="${ADD_URLS},http://arduino.esp8266.com/stable/package_esp8266com_index.json"
echo ${ADD_URLS}
${ARDUINO_DIR}/arduino \
--pref boardsmanager.additional.urls=${ADD_URLS} \
--save-prefs
# arduino [--install-boards package name:platform architecture[:version]]
${ARDUINO_DIR}/arduino --install-boards esp8266:esp8266
# Install stm32 bluepill
# http://docs.leaflabs.com/static.leaflabs.com/pub/leaflabs/maple-docs/latest/arduino-compatibility.html
# --pref boardsmanager.additional.urls="http://dan.drown.org/stm32duino/package_STM32duino_index.json" \
#${ARDUINO_DIR}/arduino --install-boards stm32duino:STM32F1
ADD_URLS="${ADD_URLS},https://github.com/stm32duino/BoardManagerFiles/raw/master/STM32/package_stm_index.json"
echo ${ADD_URLS}
${ARDUINO_DIR}/arduino \
--pref boardsmanager.additional.urls=${ADD_URLS} \
--save-prefs
## arduino [--install-boards package name:platform architecture[:version]]
${ARDUINO_DIR}/arduino --install-boards STM32:stm32
# Install NRF5x sandeepmistry https://github.com/sandeepmistry/arduino-nRF5
#name "BBC micro:bit"
#name "Bluz DK"
#name "Generic nRF51822"
#name "Generic nRF52823"
#name "OSHChip"
#name "ng-beacon"
#name "nRF51 Dongle"
#name "nRF51822 Development Kit"
#name "nRF52 DK"
#name "RedBear BLE Nano 2"
#name "RedBear Blend 2"
#name "RedBearLab BLE Nano"
#name "RedBearLab nRF51822"
#name "Waveshare BLE400"
ADD_URLS="${ADD_URLS},https://sandeepmistry.github.io/arduino-nRF5/package_nRF5_boards_index.json"
echo ${ADD_URLS}
${ARDUINO_DIR}/arduino \
--pref boardsmanager.additional.urls=${ADD_URLS} \
--save-prefs
# arduino [--install-boards package name:platform architecture[:version]]
${ARDUINO_DIR}/arduino --install-boards sandeepmistry:nRF5
NRF_HOME=${ARDUINO_TOOLS_DIR}/nRF5FlashSoftDevice/tool/
mkdir -p "${NRF_HOME}" && wget -c --directory-prefix "${NRF_HOME}" https://github.com/sandeepmistry/arduino-nRF5/releases/download/tools/nRF5FlashSoftDevice.jar
# nRF5 watches https://github.com/micooke/arduino-nRF5-smartwatches
# Smartwatch variants for sandeepmistry's Nordic Semiconductor nRF5 core
#name "IDO003"
#name "ID100HR"
#name "ID107HR"
#name "ID107HR Plus"
ADD_URLS="${ADD_URLS},https://micooke.github.io/package_nRF5_smartwatches_index.json"
${ARDUINO_DIR}/arduino \
--pref boardsmanager.additional.urls=${ADD_URLS} \
--save-prefs
## arduino [--install-boards package name:platform architecture[:version]]
${ARDUINO_DIR}/arduino --install-boards micooke:nRF5
## Install Readbear NRF5x
#cd /var/tmp || exit
#${ARDUINO_DIR}/arduino \
# --pref="boardsmanager.additional.urls=https://redbearlab.github.io/arduino/package_redbearlab_index.json"\
# --save-prefs
#
#wget -c https://raw.githubusercontent.com/RedBearLab/nRF51822-Arduino/S130/98-daplink.rules
#cp 98-daplink.rules /etc/udev/rules.d/
#
#sudo udevadm control --reload-rules
#
## Fix the upload problem on Linux 64bit system
#
#sudo apt-get install lsb-core
#
#sudo apt-get install libudev1:i386
#
#sudo ln -sf /lib/x86_64-linux-gnu/libudev.so.1 /lib/x86_64-linux-gnu/libudev.so.0
# Guru meditation decode - get a more meaningful explanation of the stack traces you get on ESP8266/ESP32.
wget -qO - https://github.com/me-no-dev/EspExceptionDecoder/releases/download/1.1.0/EspExceptionDecoder-1.1.0.zip | bsdtar -C "${ARDUINO_TOOLS_DIR}" -xvf-
# Other libraries direct from github
git clone https://github.com/adafruit/Touch-Screen-Library ~/Arduino/libraries/TouchScreen
# https://learn.adafruit.com/ahrs-for-adafruits-9-dof-10-dof-breakout/sensor-fusion-algorithmsahrs
git clone https://github.com/PaulStoffregen/MahonyAHRS ~/Arduino/libraries/MahonyAHRS
git clone https://github.com/PaulStoffregen/MadgwickAHRS ~/Arduino/libraries/MadgwickAHRS

7
020_etcher.io.sh Normal file
View File

@ -0,0 +1,7 @@
echo "deb https://deb.etcher.io stable etcher" | sudo tee /etc/apt/sources.list-available/etcher.list
ln -s /etc/apt/sources.list-available/etcher.list /etc/apt/sources.list.d/etcher.list
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 379CE192D401AB61
sudo apt-get update
sudo apt-get install etcher-electron

View File

@ -2,15 +2,15 @@
# debian is still on 0.16 but 0.17 is needed for current workbenches
# If building, use cmake gui for configuring the build.
sudo apt-get install -y cmake-qt-gui
sudo apt-get install -y cmake-qt-gui python-numpy python3-numpy z88
# the ppa has calculix-ccx eigen3 freecad-daily (0.18~beta1) opencascade
# ppa:freecad-maintainers/freecad-daily
# sudo add-apt-repository ppa:freecad-maintainers/freecad-daily
# sudo apt-get update
# YOUR_UBUNTU_VERSION_HERE=bionic # 18.04 buster/sid
YOUR_UBUNTU_VERSION_HERE=artful # 17.10 stretch/sid
YOUR_UBUNTU_VERSION_HERE=bionic # 18.04 buster/sid
# YOUR_UBUNTU_VERSION_HERE=artful # 17.10 stretch/sid
# YOUR_UBUNTU_VERSION_HERE=xenial # 16.04 stretch/sid
# YOUR_UBUNTU_VERSION_HERE=trusty # 14.04 jessie/sid
@ -18,7 +18,7 @@ sudo bash -c "cat > /etc/apt/sources.list-available/freecad-daily.list" <<EOF
deb http://ppa.launchpad.net/freecad-maintainers/freecad-daily/ubuntu $YOUR_UBUNTU_VERSION_HERE main
deb-src http://ppa.launchpad.net/freecad-maintainers/freecad-daily/ubuntu $YOUR_UBUNTU_VERSION_HERE main
EOF
sudo ln -s /etc/apt/sources.list-available/freecad-daily.list /etc/apt/sources.list.d/freecad-daily.list
sudo ln -sf /etc/apt/sources.list-available/freecad-daily.list /etc/apt/sources.list.d/freecad-daily.list
# Launchpad PPA for FreeCAD maintainers
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 19BB5BCA
@ -27,14 +27,34 @@ sudo bash -c "cat > /etc/apt/sources.list-available/freecad-stable.list" <<EOF
deb http://ppa.launchpad.net/freecad-maintainers/freecad-stable/ubuntu $YOUR_UBUNTU_VERSION_HERE main
deb-src http://ppa.launchpad.net/freecad-maintainers/freecad-stable/ubuntu $YOUR_UBUNTU_VERSION_HERE main
EOF
sudo ln -s /etc/apt/sources.list-available/freecad-stable.list /etc/apt/sources.list.d/freecad-stable.list
sudo ln -sf /etc/apt/sources.list-available/freecad-stable.list /etc/apt/sources.list.d/freecad-stable.list
sudo bash -c "cat > /etc/apt/sources.list-available/elmer.list" <<EOF
deb http://ppa.launchpad.net/elmer-csc-ubuntu/elmer-csc-ppa/ubuntu $YOUR_UBUNTU_VERSION_HERE main
deb-src http://ppa.launchpad.net/elmer-csc-ubuntu/elmer-csc-ppa/ubuntu $YOUR_UBUNTU_VERSION_HERE main
EOF
sudo ln -sf /etc/apt/sources.list-available/elmer.list /etc/apt/sources.list.d/elmer.list
sudo bash -c "cat > /etc/apt/sources.list-available/elmer.list" <<EOF
deb http://ppa.launchpad.net/elmer-csc-ubuntu/elmer-csc-ppa/ubuntu $YOUR_UBUNTU_VERSION_HERE main
deb-src http://ppa.launchpad.net/elmer-csc-ubuntu/elmer-csc-ppa/ubuntu $YOUR_UBUNTU_VERSION_HERE main
EOF
sudo ln -sf /etc/apt/sources.list-available/elmer.list /etc/apt/sources.list.d/elmer.list
sudo apt-get update
## freecad
# Signing key: 1024R/83193AA3B52FF6FCF10A1BBF005EAE8119BB5BCA (What is this?)
# Fingerprint: 83193AA3B52FF6FCF10A1BBF005EAE8119BB5BCA
sudo apt-get install -y freecad calculix-ccx
## elmer
# Signing key: 4096R/1FE4A88ACFEE8388A409F23A89358ABF9FB7E178 (What is this?)
# Fingerprint: 1FE4A88ACFEE8388A409F23A89358ABF9FB7E178
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 19BB5BCA
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 9FB7E178
sudo apt-get install -y freecad calculix-ccx elmerfem-csc
#sudo ln -s /etc/apt/sources.list-available/devuan-ceres.list /etc/apt/sources.list.d/devuan-ceres.list
#sudo apt-get update

3
020_ghack_userjs.sh Normal file
View File

@ -0,0 +1,3 @@
# The script needs to be run in each firefox profile directory.
cd /var/tmp
wget -c https://raw.githubusercontent.com/ghacksuserjs/ghacks-user.js/master/updater.sh

41
020_nvidia_cuda.sh Normal file
View File

@ -0,0 +1,41 @@
# http://developer.download.nvidia.com/compute/DevZone/docs/html/C/doc/CUDA_C_Getting_Started_Linux.pdf
https://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html#package-manager-metas
http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1704/x86_64/
# Meta Package Purpose
# cuda Installs all CUDA Toolkit and Driver packages. Handles upgrading to the next version of the cuda package when it's released.
# cuda-9-1 Installs all CUDA Toolkit and Driver packages. Remains at version 9.1 until an additional version of CUDA is installed.
# cuda-toolkit-9-1 Installs all CUDA Toolkit packages required to develop CUDA applications. Does not include the driver.
# cuda-tools-9-1 Installs all CUDA command line and visual tools.
# cuda-runtime-9-1 Installs all CUDA Toolkit packages required to run CUDA applications, as well as the Driver packages.
# cuda-compiler-9-1 Installs all CUDA compiler packages.
# cuda-libraries-9-1 Installs all runtime CUDA Library packages.
# cuda-libraries-dev-9-1 Installs all development CUDA Library packages.
# cuda-drivers Installs all Driver packages. Handles upgrading to the next version of the Driver packages when they're released.
#curl http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1704/x86_64/cuda-repo-ubuntu1704_9.1.85-1_amd64.deb | dpkg -i -
# Ubuntu
#echo '#sudo apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1704/x86_64/7fa2af80.pub' > /etc/apt/sources.list-available/cuda.list
#echo 'deb http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1704/x86_64 /' >> /etc/apt/sources.list-available/cuda.list
#ln -s /etc/apt/sources.list-available/cuda.list /etc/apt/sources.list.d/cuda.list
#
#sudo apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1704/x86_64/7fa2af80.pub
#sudo apt-get update
#sudo apt-get install cuda
# debian
apt-get install \
nvidia-cuda-toolkit \
nvidia-cuda-mps \
nvidia-visual-profiler \
nvidia-cuda-dev
# libnvidia-legacy-304xx-cuda1 - NVIDIA CUDA Driver Library (304xx legacy version)
# libnvidia-legacy-304xx-nvcuvid1 - NVIDIA CUDA Video Decoder runtime library (304xx legacy version)
# libnvidia-legacy-340xx-cuda1 - NVIDIA CUDA Driver Library (340xx legacy version)
# libnvidia-legacy-340xx-nvcuvid1 - NVIDIA CUDA Video Decoder runtime library (340xx legacy version)

22
020_photogrametry.sh Normal file
View File

@ -0,0 +1,22 @@
## VisualSFM - A Visual Structure from Motion System
# http://ccwu.me/vsfm/
VSFM_HOME=/var/tmp/vsfm
mkdir ${VSFM_HOME}
cd ${VSFM_HOME}
http://ccwu.me/vsfm/download/VisualSFM_linux_64bit.zip
# BigSFM
# MVE
http://www.gcc.tu-darmstadt.de/home/proj/mve/
# insight3d
http://insight3d.sourceforge.net/
http://sourceforge.net/projects/insight3dng/
# Optical Targets used in professional application:
http://hubbsmachine.com/5-retro-reflective-tape-target
http://hubbsmachine.com/4-retro-reflective-contrast-photogrammetry-targets

247
020_platformio-core.sh Normal file
View File

@ -0,0 +1,247 @@
# http://docs.platformio.org/en/latest/faq.html#faq-install-shell-commands
sudo apt-get install python python-pip checkinstall
# sudo python -c "$(curl -fsSL https://raw.githubusercontent.com/platformio/platformio/develop/scripts/get-platformio.py)"
# uninstall existing version
pip uninstall platformio
# install the latest development version of PlatformIO
PROJECT=platformio/platformio-core
RELEASE=$(curl "https://api.github.com/repos/${PROJECT}/releases?per_page=5" | jq -r '.[0] | .tag_name')
VERSION=$(echo "${RELEASE}" | cut -c 2- | cut -f1 -d"-")
PIO_BUILD_HOME=/var/tmp/platformio-core-"${VERSION}"
mkdir -p "${PIO_BUILD_HOME}" && cd "${PIO_BUILD_HOME}" || exit
echo "PlatformIO Core (CLI tool) for embedded programming." > description-pak
mkdir -p doc-pak && wget -c --directory-prefix doc-pak https://raw.githubusercontent.com/platformio/platformio-core/develop/README.rst
echo "http://docs.platformio.org/en/latest/userguide/index.html" > doc-pak/README
sudo checkinstall --fstrans=no pip install -U https://github.com/platformio/platformio-core/archive/"${RELEASE}".zip
# install some platforms
platformio platform install espressif8266
platformio platform install espressif32
platformio platform install nordicnrf51
platformio platform install nordicnrf52
platformio platform install ststm32
platformio platform install timsp430
platformio platform install atmelavr
# To revert to the latest stable version
#pip uninstall platformio
#pip install -U platformio
# pip install puts the results in usr/local/bin so we don't have a path issue
#platformio: /usr/local/bin/platformio
cat > ~/.zshrc.d/008_platformio.zsh << 'EOF'
if [[ -d "/usr/local/bin/platormio" ]]; then
autoload bashcompinit && bashcompinit
eval "$(_PLATFORMIO_COMPLETE=source platformio)"
eval "$(_PLATFORMIO_COMPLETE=source pio)"
fi
EOF
cat > ~/.profile << 'EOF'
if [ -d "/usr/local/bin/platformio" ] ; then
eval "$(_PLATFORMIO_COMPLETE=source platformio)"
eval "$(_PLATFORMIO_COMPLETE=source pio)"
fi
EOF
# http://docs.platformio.org/en/latest/faq.html#platformio-udev-rules
# https://raw.githubusercontent.com/platformio/platformio-core/develop/scripts/99-platformio-udev.rules
sudo bash -c "cat > /etc/udev/rules.d/99-platformio-udev.rules" << 'EOF'
#
# Boards
#
# CP210X USB UART
SUBSYSTEMS=="usb", ATTRS{idVendor}=="10c4", ATTRS{idProduct}=="ea60", MODE:="0666"
# FT232R USB UART
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", MODE:="0666"
# Prolific Technology, Inc. PL2303 Serial Port
SUBSYSTEMS=="usb", ATTRS{idVendor}=="067b", ATTRS{idProduct}=="2303", MODE:="0666"
# QinHeng Electronics HL-340 USB-Serial adapter
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="7523", MODE:="0666"
# Arduino boards
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="[08][02]*", MODE:="0666"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2a03", ATTRS{idProduct}=="[08][02]*", MODE:="0666"
# Arduino SAM-BA
ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="6124", ENV{ID_MM_DEVICE_IGNORE}="1"
ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="6124", ENV{MTP_NO_PROBE}="1"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="6124", MODE:="0666"
KERNEL=="ttyACM*", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="6124", MODE:="0666"
# Digistump boards
SUBSYSTEMS=="usb", ATTRS{idVendor}=="16d0", ATTRS{idProduct}=="0753", MODE:="0666"
KERNEL=="ttyACM*", ATTRS{idVendor}=="16d0", ATTRS{idProduct}=="0753", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1"
# STM32 discovery boards, with onboard st/linkv2
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="374?", MODE:="0666"
# USBtiny
SUBSYSTEMS=="usb", ATTRS{idProduct}=="0c9f", ATTRS{idVendor}=="1781", MODE="0666"
# USBasp V2.0
SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="05dc", MODE:="0666"
# Teensy boards
ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="04[789]?", ENV{ID_MM_DEVICE_IGNORE}="1"
ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="04[789]?", ENV{MTP_NO_PROBE}="1"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="04[789]?", MODE:="0666"
KERNEL=="ttyACM*", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="04[789]?", MODE:="0666"
#TI Stellaris Launchpad
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1cbe", ATTRS{idProduct}=="00fd", MODE="0666"
#TI MSP430 Launchpad
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0451", ATTRS{idProduct}=="f432", MODE="0666"
#
# Debuggers
#
# Black Magic Probe
SUBSYSTEM=="tty", ATTRS{interface}=="Black Magic GDB Server"
SUBSYSTEM=="tty", ATTRS{interface}=="Black Magic UART Port"
# opendous and estick
ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="204f", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Original FT232/FT245 VID:PID
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Original FT2232 VID:PID
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6010", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Original FT4232 VID:PID
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6011", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Original FT232H VID:PID
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6014", MODE="660", GROUP="plugdev", TAG+="uaccess"
# DISTORTEC JTAG-lock-pick Tiny 2
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="8220", MODE="660", GROUP="plugdev", TAG+="uaccess"
# TUMPA, TUMPA Lite
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="8a98", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="8a99", MODE="660", GROUP="plugdev", TAG+="uaccess"
# XDS100v2
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="a6d0", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Xverve Signalyzer Tool (DT-USB-ST), Signalyzer LITE (DT-USB-SLITE)
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="bca0", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="bca1", MODE="660", GROUP="plugdev", TAG+="uaccess"
# TI/Luminary Stellaris Evaluation Board FTDI (several)
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="bcd9", MODE="660", GROUP="plugdev", TAG+="uaccess"
# TI/Luminary Stellaris In-Circuit Debug Interface FTDI (ICDI) Board
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="bcda", MODE="660", GROUP="plugdev", TAG+="uaccess"
# egnite Turtelizer 2
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="bdc8", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Section5 ICEbear
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="c140", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="c141", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Amontec JTAGkey and JTAGkey-tiny
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="cff8", MODE="660", GROUP="plugdev", TAG+="uaccess"
# TI ICDI
ATTRS{idVendor}=="0451", ATTRS{idProduct}=="c32a", MODE="660", GROUP="plugdev", TAG+="uaccess"
# STLink v1
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3744", MODE="660", GROUP="plugdev", TAG+="uaccess"
# STLink v2
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3748", MODE="660", GROUP="plugdev", TAG+="uaccess"
# STLink v2-1
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="374b", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Hilscher NXHX Boards
ATTRS{idVendor}=="0640", ATTRS{idProduct}=="0028", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Hitex STR9-comStick
ATTRS{idVendor}=="0640", ATTRS{idProduct}=="002c", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Hitex STM32-PerformanceStick
ATTRS{idVendor}=="0640", ATTRS{idProduct}=="002d", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Altera USB Blaster
ATTRS{idVendor}=="09fb", ATTRS{idProduct}=="6001", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Amontec JTAGkey-HiSpeed
ATTRS{idVendor}=="0fbb", ATTRS{idProduct}=="1000", MODE="660", GROUP="plugdev", TAG+="uaccess"
# SEGGER J-Link
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="0101", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="0102", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="0103", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="0104", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="0105", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="0107", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="0108", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="1010", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="1011", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="1012", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="1013", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="1014", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="1015", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="1016", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="1017", MODE="660", GROUP="plugdev", TAG+="uaccess"
ATTRS{idVendor}=="1366", ATTRS{idProduct}=="1018", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Raisonance RLink
ATTRS{idVendor}=="138e", ATTRS{idProduct}=="9000", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Debug Board for Neo1973
ATTRS{idVendor}=="1457", ATTRS{idProduct}=="5118", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Olimex ARM-USB-OCD
ATTRS{idVendor}=="15ba", ATTRS{idProduct}=="0003", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Olimex ARM-USB-OCD-TINY
ATTRS{idVendor}=="15ba", ATTRS{idProduct}=="0004", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Olimex ARM-JTAG-EW
ATTRS{idVendor}=="15ba", ATTRS{idProduct}=="001e", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Olimex ARM-USB-OCD-TINY-H
ATTRS{idVendor}=="15ba", ATTRS{idProduct}=="002a", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Olimex ARM-USB-OCD-H
ATTRS{idVendor}=="15ba", ATTRS{idProduct}=="002b", MODE="660", GROUP="plugdev", TAG+="uaccess"
# USBprog with OpenOCD firmware
ATTRS{idVendor}=="1781", ATTRS{idProduct}=="0c63", MODE="660", GROUP="plugdev", TAG+="uaccess"
# TI/Luminary Stellaris In-Circuit Debug Interface (ICDI) Board
ATTRS{idVendor}=="1cbe", ATTRS{idProduct}=="00fd", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Marvell Sheevaplug
ATTRS{idVendor}=="9e88", ATTRS{idProduct}=="9e8f", MODE="660", GROUP="plugdev", TAG+="uaccess"
# Keil Software, Inc. ULink
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="2710", MODE="660", GROUP="plugdev", TAG+="uaccess"
# CMSIS-DAP compatible adapters
ATTRS{product}=="*CMSIS-DAP*", MODE="660", GROUP="plugdev", TAG+="uaccess"
EOF

View File

@ -1,32 +1,46 @@
## pycharm python ide
#PYCHARM_VERSION=2016.3
#cd /var/tmp && wget -c https://d1opms6zj7jotq.cloudfront.net/python/pycharm-community-${PYCHARM_VERSION}.tar.gz && tar xzvf /var/tmp/pycharm-community-${PYCHARM_VERSION}.tar.gz
#cd /var/tmp/pycharm-community-${PYCHARM_VERSION}
PYCHARM_VERSION=2018.1.4
cd /var/tmp && wget -c https://download.jetbrains.com/python/pycharm-community-${PYCHARM_VERSION}.tar.gz && tar xzvf /var/tmp/pycharm-community-${PYCHARM_VERSION}.tar.gz
#cat << EF > ./install_pycharm.sh
#PYCHARM_VERSION=${PYCHARM_VERSION}
##cd /var/tmp
##wget -c http://download-cf.jetbrains.com/python/pycharm-community-${PYCHARM_VERSION}.tar.gz
#tar xzvf /var/tmp/pycharm-community-${PYCHARM_VERSION}.tar.gz -C /opt
#ln -fs /opt/pycharm-community-${PYCHARM_VERSION} /opt/pycharm
#ln -s /opt/pycharm/bin/pycharm.sh /usr/local/bin/pycharm
#ln -s /opt/pycharm/bin/inspect.sh /usr/local/bin/inspect
#cat << EOF > /opt/pycharm/pycharm.desktop
#[Desktop Entry]
#Type=Application
#Name=pyCharm IDE
#GenericName=Integrated Development Environment
#Comment=An IDE for the python programming language
#Exec=/opt/pycharm/bin/pycharm.sh
#Icon=/opt/pycharm/bin/pycharm.png
#Terminal=false
#Categories=Development;IDE;Electronics;
#MimeType=text/x-python
#Keywords=python;programming;ide;
#EOF
#EF
cd /var/tmp/pycharm-community-${PYCHARM_VERSION} || exit
cat << EF > ./install_pycharm.sh
PYCHARM_VERSION=${PYCHARM_VERSION}
cd /var/tmp || exit
#wget -c http://download.jetbrains.com/python/pycharm-community-${PYCHARM_VERSION}.tar.gz
tar xzvf /var/tmp/pycharm-community-${PYCHARM_VERSION}.tar.gz -C /opt
ln -sf /opt/pycharm-community-${PYCHARM_VERSION} /opt/pycharm
ln -sf /opt/pycharm/bin/pycharm.sh /usr/local/bin/pycharm
ln -sf /opt/pycharm/bin/inspect.sh /usr/local/bin/inspect
cat << EOF > /opt/pycharm/pycharm.desktop
[Desktop Entry]
Type=Application
Name=pyCharm IDE
GenericName=Integrated Development Environment
Comment=An IDE for the python programming language
Exec=/opt/pycharm/bin/pycharm.sh
Icon=/opt/pycharm/bin/pycharm.png
Terminal=false
Categories=Development;IDE;Electronics;
MimeType=text/x-python
Keywords=python;programming;ide;
EOF
EF
cat << EOF > ./description-pak
PyCharm is an integrated development environment (IDE) used for the Python language.
Coding assistance and analysis, with code completion, syntax and error highlighting, linter integration.
Python refactoring: extract method, introduce variable, introduce constant, pull up and push down.
Support for web frameworks: Django, web2py and Flask
Integrated Python debugger.
Integrated unit testing, with line-by-line code coverage.
Google App Engine Python development.
Version control integration: unified user interface for git.
EOF
echo 'checkinstall -y --fstrans=no --install=no bash ./install_pycharm.sh 2>&1 | tee err' > checkinstall_pycharm.sh && bash ./checkinstall_pycharm.sh
dpkg -i /var/tmp/pycharm-community-${PYCHARM_VERSION}/pycharm-community_${PYCHARM_VERSION}-1_amd64.deb
dpkg -i /var/tmp/pycharm-community-"${PYCHARM_VERSION}"/pycharm-community_"${PYCHARM_VERSION}"-1_amd64.deb

9
020_python-jf.sh Normal file
View File

@ -0,0 +1,9 @@
PROJECT=alhoo/jf
#RELEASE=$(curl --silent "https://api.github.com/repos/${PROJECT}/releases/latest" | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/')
RELEASE=$(curl "https://api.github.com/repos/${PROJECT}/tags?per_page=5" | jq -r '.[0] | .name')
JF_BUILD_HOME=/var/tmp/python-jf-"${RELEASE}"
mkdir -p "${JF_BUILD_HOME}" && cd "${JF_BUILD_HOME}" || exit
echo "JF, is a jq-clone written in python. It supports evaluation of python oneliners, making it especially appealing for data scientists who are used to working with python." > description-pak
mkdir -p doc-pak && wget -c --directory-prefix doc-pak https://raw.githubusercontent.com/${PROJECT}/develop/README.rst
sudo checkinstall --fstrans=no pip install -U https://github.com/${PROJECT}/archive/"${RELEASE}".zip

10
020_riot.sh Normal file
View File

@ -0,0 +1,10 @@
sudo sh -c "echo 'deb https://riot.im/packages/debian/ artful main' > /etc/apt/sources.list-available/matrix-riot-im.list"
sudo ln -s /etc/apt/sources.list-available/matrix-riot-im.list /etc/apt/sources.list.d/matrix-riot-im.list
# Add the public key:
curl -L https://riot.im/packages/debian/repo-key.asc | sudo apt-key add -
sudo apt-get update && apt-get -y install riot-web

View File

@ -169,10 +169,11 @@ set -g pane-active-border-fg colour069 # 24 blue
# set -g pane-active-border-bg black
EOF
mkdir -p ~/.zshrc.d/
echo "source /usr/share/zsh/vendor_completions/_tmuxinator" > ~/.zshrc.d/006_tmuxinator.zsh
#mkdir -p ~/.zshrc.d/
#echo "source /usr/share/zsh/vendor_completions/_tmuxinator" > ~/.zshrc.d/006_tmuxinator.zsh
mkdir -p ~/.tmux/plugins/tpm
mkdir -p ~/.tmux/.tmuxp
#cat > ~/.config/tmux/tmux.conf << 'EOF'
cat > ~/.tmux.conf << 'EOF'
@ -238,6 +239,19 @@ set -g @tpm_plugins ' \
# tmux-plugins/tmux-sensible \
#'
# tmux-resurrect will now restore vim and neovim sessions if `Session.vim` file is present.
# for vim resurrect
set -g @rsurrect-strategy-vim 'session'
# for neovim resurrect
set -g @resurrect-strategy-nvim 'session'
# panes
set -g @resurrect-capture-pane-contents 'on'
# shell history
set -g @resurrect-save-shell-history 'on'
# Initialize TMUX plugin manager
#run '~/.tmux/plugins/tpm/tpm'

View File

@ -4,8 +4,10 @@
#apt-get update
#apt-get install unetbootin
VERSION=661
cd /var/tmp
wget -c https://github.com/unetbootin/unetbootin/releases/download/655/unetbootin-linux64-655.bin
chmod +x ./unetbootin-linux-*
wget -c https://github.com/unetbootin/unetbootin/releases/download/${VERSION}/unetbootin-linux64-${VERSION}.bin
chmod +x ./unetbootin-linux64-${VERSION}.bin
apt-get install p7zip-full
./unetbootin-linux-*
./unetbootin-linux64-${VERSION}.bin

View File

@ -60,6 +60,11 @@ set showmatch
let python_highlight_all = 1
syntax on
" Shortcut to rapidly toggle `set list`
nmap <leader>l :set list!<CR>
" Use the same symbols as TextMate for tabstops and EOLs
set listchars=tab:▸\ ,eol:¬
" tmux will only forward escape sequences to the terminal if surrounded by a DCS sequence
" http://sourceforge.net/mailarchive/forum.php?thread_name=AANLkTinkbdoZ8eNR1X2UobLTeww1jFrvfJxTMfKSq-L%2B%40mail.gmail.com&forum_name=tmux-users
@ -136,6 +141,7 @@ call vundle#begin()
Plugin 'VundleVim/Vundle.vim'
" plugin on GitHub repos
Plugin 'joonty/vdebug'
Plugin 'tpope/vim-fugitive'
Plugin 'jreybert/vimagit'
Plugin 'wincent/command-t'
@ -162,8 +168,17 @@ Plugin 'edkolev/tmuxline.vim'
Plugin 'terryma/vim-multiple-cursors'
Plugin 'sudar/vim-arduino-syntax'
Plugin 'ekalinin/Dockerfile.vim'
Plugin ' mattboehm/vim-unstack'
Plugin 'tmux-plugins/vim-tmux'
" vim-snipmate
Plugin 'MarcWeber/vim-addon-mw-utils'
Plugin 'tomtom/tlib_vim'
Plugin 'garbas/vim-snipmate
" Optional:
Plugin 'honza/vim-snippets'
" requires tmux.conf setting: set -g focus-events on or tmux-plugins/tmux-sensible plugin.
Plugin 'tmux-plugins/vim-tmux-focus-events'
@ -178,6 +193,13 @@ Plugin 'majutsushi/tagbar'
Plugin 'scrooloose/nerdtree'
Plugin 'jistr/vim-nerdtree-tabs'
map <F2> :NERDTreeToggle<CR>
silent! nmap <C-p> :NERDTreeToggle<CR>
silent! map <F3> :NERDTreeFind<CR>
let g:NERDTreeMapActivateNode="<F3>"
let g:NERDTreeMapPreview="<F4>"
Plugin 'saltstack/salt-vim'
Plugin 'plasticboy/vim-markdown'
Plugin 'fatih/vim-go'
@ -188,7 +210,7 @@ Plugin 'jmcantrell/vim-virtualenv'
Plugin 'fisadev/vim-isort' " Automatically sort python imports
" Python mode (indentation, doc, refactor, lints, code checking, motion and
" operators, highlighting, run and ipdb breakpoints)
Plugin 'klen/python-mode'
Plugin 'python-mode/python-mode
Plugin 'scrooloose/syntastic'
Plugin 'scrooloose/nerdcommenter'
Plugin 'sbdchd/neoformat'

View File

@ -2,16 +2,18 @@
set -e
mkdir -p /etc/apt//sources.list-available || exit
cat > /etc/apt/sources.list-available/waterfox.list << EOF
# curl https://bintray.com/user/downloadSubjectPublicKey\?username\=hawkeye116477 | sudo apt-key add -
deb https://dl.bintray.com/hawkeye116477/waterfox-deb release main
# wget -nv https://download.opensuse.org/repositories/home:hawkeye116477:waterfox/Debian_Testing/Release.key -O Release.key
# apt-key add - < Release.key
deb http://download.opensuse.org/repositories/home:/hawkeye116477:/waterfox/Debian_Testing/ /
EOF
# The dl-bintray repo doesn't play nice with apt-proxy
echo "Acquire::http::Proxy { dl.bintray.com DIRECT; };" >> /etc/apt/apt.conf.d/02proxy
#echo "Acquire::http::Proxy { dl.bintray.com DIRECT; };" >> /etc/apt/apt.conf.d/02proxy
ln -sf /etc/apt/sources.list-available/waterfox.list /etc/apt/sources.list.d/waterfox.list
curl "https://bintray.com/user/downloadSubjectPublicKey\?username\=hawkeye116477" | sudo apt-key add -
wget -nv https://download.opensuse.org/repositories/home:hawkeye116477:waterfox/Debian_Testing/Release.key -O Release.key
apt-key add - < Release.key
apt-get update

42
firefox-speedup.example Normal file
View File

@ -0,0 +1,42 @@
# browser.safebrowsing.remoteLookups unset
# browser.cache.use_new_backend 1
# network.http.pipelining.ssl true
# network.http.pipelining true
# network.http.proxy.pipelining true
# network.http.pipelining.maxrequests 120
# network.dns.disableIPv6 true
# browser.safebrowsing.malware.enabled false
# browser.cache.disk.enable false
# browser.cache.memory.enable true
# browser.cache.memory.capacity integer 204800
PROFILE_NAME=ybokieeb
cd ${HOME}/.mozilla/firefox/
cp -a ${PROFILE_NAME}.default/ profile.bac
rm -rf profile_name.default/*
echo "tmpfs /home/${USER}/.mozilla/firefox/${PROFILE_NAME}.default tmpfs size=128M,user,exec,uid=1000,gid=1000 0 0" >> /etc/fstab
sudo mount -a
cd ${HOME}/.mozilla/firefox/
cp -a profile.bac/* ${PROFILE_NAME}.default/
echo > /usr/local/bin/ff_profile_sync < "EOF"
#!/bin/sh
cd /home/${USER}/.mozilla/firefox/
if test -d *.default;then
if test -d profile.bac;then
rsync -a --delete *.default/ profile.bac/
fi;fi
EOF
(crontab -l 2>/dev/null; echo "*/5 * * * * /usr/local/bin/ff_profile_sync > /dev/null 2>&1") | crontab -

View File

@ -7,7 +7,7 @@ case "$DOCKED" in
#undocked event - lets remove all connected outputs apart from LVDS
for output in $(/usr/bin/xrandr -d :0.0 --verbose|grep " connected"|grep -v LVDS|awk '{print $1}')
do
/usr/bin/xrandr -d :0.0 --output $output --off
/usr/bin/xrandr -d :0.0 --output "$output" --off
done
;;
"1")