diff --git a/001_apt-group.sh b/001_apt-group.sh new file mode 100644 index 0000000..cb804e8 --- /dev/null +++ b/001_apt-group.sh @@ -0,0 +1 @@ +usermod -g 3003 _apt diff --git a/001_apt-sources.sh b/001_apt-sources.sh index f848e94..9cbe9ca 100644 --- a/001_apt-sources.sh +++ b/001_apt-sources.sh @@ -1,21 +1,17 @@ # avoid duplicates set -x rm /etc/apt/sources.list -rm /etc/apt/sources.list.d/devuan +rm /etc/apt/sources.list.d/devuan.list ACTIVE=/etc/apt/sources.list.d AVAILABLE=/etc/apt/sources.list-available mkdir -p "${AVAILABLE}" -SECTION=( 'main' 'contrib' 'non-free' ) -echo ${#SECTION[@]} -echo ${SECTION[@]} -echo ${SECTION[1]} -echo ${SECTION[2]} -echo ${SECTION[3]} -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' ) -OTHER_LIST=( 'experimental' ) +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') + +OTHER_LIST=('experimental') echo ${#ACTIVE_LIST[@]} for RELEASE in "${ACTIVE_LIST[@]}"; do @@ -61,7 +57,8 @@ bash -c cat > "${AVAILABLE}"/docker.list <%Creset' git config --global alias.lg "log --oneline --abbrev-commit --all --graph --decorate --color --date=relative --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset'" + +# see the problems with git pull: https://stackoverflow.com/questions/15316601/in-what-cases-could-git-pull-be-harmful/15316602#15316602 +git config --global alias.up '!git remote update -p; git merge --ff-only @{u}' diff --git a/010_initramfs_resume.sh b/010_initramfs_resume.sh index a3621e6..2b78d33 100644 --- a/010_initramfs_resume.sh +++ b/010_initramfs_resume.sh @@ -10,7 +10,7 @@ # You should set the RESUME variable in INITRAMFS_HOME=/etc/initramfs-tools/conf.d/ -DEVICE=${1:/dev/sda7} +DEVICE=${1:-/dev/sda7} RESUME="RESUME=${DEVICE}" #UUID=f4d19cc8-2c3e-4061-a618-7974cb88bfec #RESUME="RESUME=none" diff --git a/010_openrc.sh b/010_openrc.sh index 8de9742..f084105 100644 --- a/010_openrc.sh +++ b/010_openrc.sh @@ -1,4 +1,4 @@ -# cgroups uses sysvinit but from 0.2.5 can replace it. ascii version currently 0.2.3 +# openrc uses sysvinit but from 0.2.5 can replace it. ascii version currently 0.2.3 apt-get install sysvinit-core apt-get install util-linux sysvinit-utils apt-get install initscripts openrc diff --git a/010_python.sh b/010_python.sh new file mode 100644 index 0000000..922f1c7 --- /dev/null +++ b/010_python.sh @@ -0,0 +1,7 @@ +apt-get install -y python-dev python3-dev +apt-get install -y python3-requests +apt-get install -y python3-autopep8 +apt-get install -y python3-ipython +apt-get install -y python3-pylint +apt-get install -y virtualenvwrapper +apt-get install -y prospector diff --git a/010_tig.sh b/010_tig.sh deleted file mode 100644 index 293c7d4..0000000 --- a/010_tig.sh +++ /dev/null @@ -1 +0,0 @@ -apt-get install tig diff --git a/020_bunsenlabs.sh b/020_bunsenlabs.sh new file mode 100644 index 0000000..d01a07c --- /dev/null +++ b/020_bunsenlabs.sh @@ -0,0 +1,221 @@ +# A debian based collection of openbox/tint2/conky themes + +RELEASE=hydrogen +RELEASE=deuterium # derived from Debian Jessie. +RELEASE=helium # derived from Debian Stretch +DEBIAN_FRONTEND=noninteractive + +apt-get install -y bunsen-keyring + +#curl -s https://pkg.bunsenlabs.org/BunsenLabs-${RELEASE}.asc | \ +# gpg --with-fingerprint - | \ +# apt-key add - + +# hydrogen +#echo "deb http://pkg.bunsenlabs.org/debian bunsen-hydrogen main" > /etc/apt/sources.list-available/bunsen-hydrogen.list + +#echo "deb http://pkg.bunsenlabs.org/debian jessie-backports main" > /etc/apt/sources.list-available/bunsen-jessie-backports.list + +#ln -s /etc/apt/sources.list-available/bunsen-hydrogen.list /etc/apt/sources.list.d/bunsen-hydrogen.list + +#ln -s /etc/apt/sources.list-available/bunsen-jessie-backports.list /etc/apt/sources.list.d/bunsen-jessie-backports.list + +# helium +echo "deb http://pkg.bunsenlabs.org/debian bunsen-helium main" > /etc/apt/sources.list-available/bunsen-helium.list + +echo "deb http://pkg.bunsenlabs.org/debian stretch-backports main" > /etc/apt/sources.list-available/bunsen-stretch-backports.list + +echo "deb http://pkg.bunsenlabs.org/debian unstable main" > /etc/apt/sources.list-available/bunsen-other.list + +ln -s /etc/apt/sources.list-available/bunsen-helium.list /etc/apt/sources.list.d/bunsen-helium.list + +ln -s /etc/apt/sources.list-available/bunsen-stretch-backports.list /etc/apt/sources.list.d/bunsen-stretch-backports.list + +ln -s /etc/apt/sources.list-available/bunsen-other.list /etc/apt/sources.list.d/bunsen-other.list + +apt-get update + +# These are the base packages for a bunsenized openbox system +#apt-get install -y \ +# bunsen-os-release \ +# bunsen-thunar \ +# bunsen-welcome \ +# bunsen-pipemenus \ +# bunsen-themes \ +# bunsen-common \ +# bunsen-docs \ +# bunsen-images \ +# bunsen-keyring \ +# bunsen-welcome \ +# bunsen-configs \ +# bunsen-python-apt-template \ +# bunsen-conky \ +# bunsen-faenza-icon-theme \ +# bunsen-meta-libreoffice \ +# bunsen-utilities \ +# tint2 \ +# geany \ +# openbox \ +# obconf \ +# obmenu \ +# thunar + +# bunsen-meta-all pulls in more gnome/policykit/pulseaudio related deps +#Recommends: +# evince, +# btrfs-tools, +# transmission-gtk, +# network-manager-gnome, +# pulseaudio, +# pulseaudio-module-x11, +# pavucontrol, +# synaptic, +# gnome-keyring, +# policykit-1-gnome, +# gvfs, +# gvfs-backends, +# gvfs-fuse, +# +# bunsen-common, +# bunsen-configs, +# bunsen-conky, +# bunsen-docs, +# bunsen-faenza-icon-theme, +# bunsen-images, +# bunsen-keyring, +# bunsen-os-release, +# bunsen-pipemenus, +# bunsen-themes, +# bunsen-thunar, +# bunsen-utilities, +# bunsen-welcome +# alsa-utils, +# anacron, +# apt-transport-https, +# apt-xapian-index, +# aptitude, +# arandr, +# arj, +# at-spi2-core, +# bash-completion, +# catfish, +# clipit, +# compton, +# conky-all, +# cpufrequtils, +# curl, +# crda, +# dmz-cursor-theme, +# dosfstools, +# eject, +# enchant, +# fbxkb, +# fdpowermon, +# feh, +# file-roller, +# filezilla, +# firefox-esr, +# firmware-b43-installer, +# firmware-b43legacy-installer, +# firmware-linux, +# fonts-cantarell, +# fonts-dejavu, +# fonts-droid, +# fonts-inconsolata, +# fonts-liberation, +# ftp, +# fuse, +# galculator, +# galternatives, +# gdebi, +# geany, +# ghostscript, +# gigolo, +# gksu, +# gmrun, +# gnumeric, +# gparted, +# gsimplecal, +# gstreamer1.0-libav, +# gstreamer1.0-plugins-bad, +# gstreamer1.0-plugins-base, +# gstreamer1.0-plugins-good, +# gstreamer1.0-plugins-ugly, +# gstreamer1.0-pulseaudio, +# hardinfo, +# hdparm, +# hddtemp, +# hexchat, +# htop, +# hwdata, +# i965-va-driver, +# lame, +# libpam-gnome-keyring, +# libreoffice-writer, +# libreoffice-gtk, +# libnotify-bin, +# lightdm, +# light-locker, +# lm-sensors, +# locales, +# lsb-release, +# lxappearance, +# lzop, +# mirage, +# mlocate, +# modemmanager, +# nitrogen, +# ntfs-3g, +# ntp, +# obconf, +# openbox, +# openssh-client, +# p7zip-full, +# pciutils, +# pcmciautils, +# python-keybinder, +# python-notify, +# python-xdg, +# rfkill, +# rpl, +# rsync, +# rzip, +# scrot, +# smartmontools, +# suckless-tools, +# sudo, +# terminator, +# thunar, +# thunar-archive-plugin, +# thunar-media-tags-plugin, +# thunar-volman, +# tint2, +# ttf-mscorefonts-installer, +# tumbler, +# unace, +# unalz, +# unar, +# unrar, +# unzip, +# update-inetd, +# usb-modeswitch, +# usbutils, +# user-setup, +# uuid-runtime, +# va-driver-all, +# vdpau-va-driver, +# vlc, +# vlc-plugin-notify, +# volumeicon-alsa, +# wireless-tools, +# xdg-user-dirs, +# xdg-utils, +# xfburn, +# xfce4-notifyd, +# xfce4-power-manager, +# xfce4-screenshooter, +# xinput, +# xorg, +# xsel, +# xz-utils, +# zip, diff --git a/020_chkconfig.sh b/020_chkconfig.sh deleted file mode 100644 index b31a67f..0000000 --- a/020_chkconfig.sh +++ /dev/null @@ -1 +0,0 @@ -apt-get install chkconfig diff --git a/020_console.sh b/020_console.sh index 44dedd8..5b50599 100644 --- a/020_console.sh +++ b/020_console.sh @@ -24,4 +24,4 @@ sed -i 's,^\(CODESET=\).*,\1'\"guess\"',' /etc/default/console-setup sed -i 's,^\(FONTFACE=\).*,\1'\"Terminess\ Powerline\"',' /etc/default/console-setup sed -i 's,^\(FONTSIZE=\).*,\1'\"8x16\"',' /etc/default/console-setup sed -i 's,^\(VIDEOMODE=\).*,\1'\"\"',' /etc/default/console-setup -echo "FONT=/usr/share/fonts/PSF/ter-powerline-v16b.psf" >> /etc/default/console-setup +echo "FONT=/usr/share/fonts/PSF/ter-powerline-v16b.psf.gz" >> /etc/default/console-setup diff --git a/020_deprecated-sysv-utils.sh b/020_deprecated-sysv-utils.sh new file mode 100644 index 0000000..cc351f0 --- /dev/null +++ b/020_deprecated-sysv-utils.sh @@ -0,0 +1,2 @@ +apt-get install -y sysv-rc-conf +apt-get install -y chkconfig diff --git a/020_fonts.sh b/020_fonts.sh new file mode 100644 index 0000000..014ceb7 --- /dev/null +++ b/020_fonts.sh @@ -0,0 +1,75 @@ +#!/bin/bash +set -e +set -x +# A collection of fonts to install to support nerdfont/powerline patched fonts that are missing. + +#http://nerdfonts.com/#downloads +#https://github.com/ryanoasis/nerd-fonts/releases/download/v1.1.0/DejaVuSansMono.zip + +RELEASE=$(curl -s https://api.github.com/repos/ryanoasis/nerd-fonts/releases/latest | grep tarball_url | cut -d '"' -f 4 | awk -F "/" {'print $8'}) +FONT_NAMES=( \ + # 3270 \ + # AnonymousPro \ + # AurulentSansMono \ + # BitstreamVeraSansMono \ + # CodeNewRoman \ + DejaVuSansMono \ + # DroidSansMono \ + # FantasqueSansMono \ + # FiraCode \ + # FiraMono \ + # Gohu \ + # Hack \ + # Hasklig \ + # HeavyData \ + # Hermit \ + # Inconsolata \ + # InconsolataGo \ + # Iosevka \ + # Lekton \ + # LiberationMono \ + Meslo \ + # Monofur \ + # Monoid \ + # Mononoki \ + # MPlus \ + # ProFont \ + # ProggyClean \ + # RobotoMono \ + # ShareTechMono \ + # SourceCodePro \ + # SpaceMono \ + Terminus \ + # Ubuntu \ + # UbuntuMono \ +) + +TMP_DIR=/var/tmp + +#FONT_DIR=/usr/share/fonts/truetype +FONT_DIR=/usr/local/share/fonts/truetype +#FONT_DIR=~/.fonts +#FONT_DIR=~/.local/share/fonts/truetype + +URL_ROOT=https://github.com/ryanoasis/nerd-fonts/releases/download + +mkdir -p ${FONT_DIR} +mkdir -p ${TMP_DIR} + +# Will get only the selected fonts +for FONT in "${FONT_NAMES[@]}"; do + wget -c --directory-prefix="${TMP_DIR}" ${URL_ROOT}/${RELEASE}/${FONT}.zip + mkdir -p "${FONT_DIR}"/"${FONT}"-nerd + unzip "${TMP_DIR}"/"${FONT}".zip -d "${FONT_DIR}"/${FONT}-nerd/ +done + +## Will get all available fonts +#URL_LIST=$(curl -s https://api.github.com/repos/ryanoasis/nerd-fonts/releases/latest | grep browser_download_url | cut -d '"' -f 4) +#for URL in "${URL_LIST[@]}"; do +# wget -c --directory-prefix="${TMP_DIR}" "${FONT_NAME}" +# FONT_NAME=$(echo "${URL}" | awk -F '/' {'print $9'} | awk -F "." {'print $1'}) +# mkdir -p "${FONT_DIR}"/"${FONT_NAME}"-nerd +# unzip "${TMP_DIR}"/"${FONT_NAME}".zip -d "${FONT_DIR}" +#done + +fc-cache -f -v diff --git a/020_git-cola.sh b/020_git-cola.sh new file mode 100644 index 0000000..18c841b --- /dev/null +++ b/020_git-cola.sh @@ -0,0 +1,2 @@ +apt-get -y install git-cola +apt-get -y install meld diff --git a/020_git-lfs.sh b/020_git-lfs.sh new file mode 100644 index 0000000..7c85703 --- /dev/null +++ b/020_git-lfs.sh @@ -0,0 +1,76 @@ +#!/usr/bin/env bash +set -x +# Using in combination with bfg to remove large binary files from a git repo and replace them with a pointer to a uri/url +# debianized repo +# git clone https://github.com/git-lfs/git-lfs + +#dist=$(lsb_release -c | cut -f2) +dist=$(cat /etc/devuan_version | awk -F '/' {'print $1'}) +if [ "$dist" == 'jessie' ] +then + DIST='jessie' +elif [ "$dist" == 'ascii' ] +then + DIST='stretch' +else [ "$dist" == 'ceres' ] + DIST='sid' +fi + +OS=debian + +DEST=/etc/apt/sources.list-available +LINK=/etc/apt/sources.list.d +mkdir -p ${DEST} +mkdir -p ${LINK} + +cat > ${DEST}/git-lfs.list << EOF +deb https://packagecloud.io/github/git-lfs/${OS}/ ${DIST} main +deb-src https://packagecloud.io/github/git-lfs/${OS}/ ${DIST} main +EOF + +ln -sf ${DEST}/git-lfs.list ${LINK}/git-lfs.list + +gpg_key_url="https://packagecloud.io/github/git-lfs/gpgkey" + +echo -n "Importing packagecloud gpg key... " + # import the gpg key + curl -L "${gpg_key_url}" 2> /dev/null | apt-key add - &>/dev/null +echo "done." + +apt-get update + +apt-get install -y git-lfs +apt-get -f install -y + + +echo "See: http://github.com/git-lfs/git-lfs/wiki/Tutorial" + +echo "Per user: + git lfs install" +echo "Per repo: + git lfs install --local" +echo "Use --skip-smudge to prevent automatic download on clone/pull" +echo "Add pattern to track with:" +echo " git lfs track '*.tar.xz'" +echo "and add the resulting .gitattribute to the repo with:" +echo " git add .gitattrubute" +echo "To see the LFS url:" +echo " git lfs env | grep 'Endpoint='" +echo "To set it:" +echo " git config -f .lfsconfig lfs.url https://my_other_server.example.com/foo/bar/info/lfs'" +echo " git add .lfsconfig" +echo "For servers see:" +echo " https://docs.gitlab.com/ce/workflow/lfs/manage_large_binaries_with_git_lfs.html" +echo " https://about.gitlab.com/2017/01/30/getting-started-with-git-lfs-tutorial/" +echo "Migration:" +echo "Rewrite e.g. all *.mp4 video files on the current branch that are not present on a remote:" +echo ' git lfs migrate import --include="*.tar.xz"' +echo "rewrite all *.mp4 video files on a given branch(es) regardless of whether they are present on a remote (may require a force-push):" +echo " "git lfs migrate import --include="*.mp4" --include-ref=refs/heads/master --include-ref=refs/heads/my-feature" +echo "Fast checkout procedure:" +echo "Checkout without tracked file downloads" +echo " GIT_LFS_SKIP_SMUDGE=1 git clone https://github.com/username/my_lfs_repo.git destination_dir" +echo " #git lfs ls-files # optionally see all the - showing the lfs files are not checked out" +echo "Pull to download the track files:." +echo " git lfs pull" +echo " #git lfs ls-files # optionally see all the * showing the lfs files are checked out" diff --git a/020_hexchat.sh b/020_hexchat.sh index 137276b..c0ace69 100644 --- a/020_hexchat.sh +++ b/020_hexchat.sh @@ -200,6 +200,13 @@ F=19 D=0 S=irc.deltaanime.net +N=Dyne +E=UTF-8 (Unicode) +F=19 +D=0 +S=irc.dyne.org/6667 +J=#dowse + N=EFnet E=UTF-8 (Unicode) F=19 diff --git a/020_jitsi.sh b/020_jitsi.sh index 9bf2213..9264102 100644 --- a/020_jitsi.sh +++ b/020_jitsi.sh @@ -1,23 +1,27 @@ -cat > /etc/apt/sources.list-available/jitsi-unstable.list << 'EOF' +cat > /etc/apt/sources.list-available/jitsi-stable.list << 'EOF' # wget -qO - https://download.jitsi.org/jitsi-key.gpg.key | apt-key add - -deb http://download.jitsi.org/deb stable/ +deb http://download.jitsi.org stable/ EOF -cat > /etc/apt/sources.list-available/jitsi-unstable.list << 'EOF' +cat > /etc/apt/sources.list-available/jitsi-testing.list << 'EOF' # wget -qO - https://download.jitsi.org/jitsi-key.gpg.key | apt-key add - -deb http://download.jitsi.org/deb testing/ +deb http://download.jitsi.org testing/ EOF # Nightly cat > /etc/apt/sources.list-available/jitsi-unstable.list << 'EOF' # wget -qO - https://download.jitsi.org/jitsi-key.gpg.key | apt-key add - -deb http://download.jitsi.org/deb unstable/ +deb http://download.jitsi.org unstable/ EOF -ln -s /etc/apt/sources.list-available/jitsi-unstable.list /etc/apt/sources.list.d/jitsi-unstable.list +ln -sf /etc/apt/sources.list-available/jitsi-unstable.list /etc/apt/sources.list.d/jitsi-unstable.list wget -qO - https://download.jitsi.org/jitsi-key.gpg.key | apt-key add - +# jitsi unstable GPG error: NO_PUBKEY C697D823EB0AB654 +apt-key adv --keyserver keyserver.ubuntu.com --recv-keys C697D823EB0AB654 + + # Update your package list: apt-get -y update diff --git a/020_neovim.sh b/020_neovim.sh index 0e2c653..6410ae5 100644 --- a/020_neovim.sh +++ b/020_neovim.sh @@ -35,12 +35,14 @@ call vundle#rc() " core plugins Bundle "gmarik/vundle" Bundle "flazz/vim-colorschemes" -Bundle "kien/ctrlp.vim" +"Bundle "kien/ctrlp.vim" +Bundle "ctrlpvim/ctrlp.vim" " vim main plugins Bundle "sjl/gundo.vim" Bundle "bling/vim-airline" Bundle "vim-airline/vim-airline-themes" +Bundle "ryanoasis/vim-devicons" Bundle "jlanzarotta/bufexplorer" Bundle "scrooloose/syntastic.git" Bundle "vim-scripts/tComment" @@ -49,6 +51,7 @@ Bundle "mileszs/ack.vim" Bundle "rking/ag.vim" Bundle "edsono/vim-matchit" Bundle "tpope/vim-fugitive" +Bundle 'jreybert/vimagit' Bundle "henrik/vim-indexed-search" Bundle "tpope/vim-abolish" Bundle "tpope/vim-repeat" @@ -66,6 +69,7 @@ Bundle "scrooloose/nerdtree" Bundle "tpope/vim-vinegar" Bundle "vim-scripts/taglist.vim" Bundle "majutsushi/tagbar" +Bundle "sbdchd/neoformat" " language vundles Bundle "pangloss/vim-javascript" @@ -83,7 +87,8 @@ Bundle "vim-scripts/SQLUtilities" Bundle "NagatoPain/AutoSQLUpperCase.vim" " autocomplete -Bundle "Valloric/YouCompleteMe" +" Bundle "Valloric/YouCompleteMe" +Bundle 'davidhalter/jedi-vim' Bundle "MarcWeber/vim-addon-mw-utils" Bundle "tomtom/tlib_vim" @@ -255,12 +260,53 @@ let g:airline#extensions#tabline#tab_nr_type = 1 " tab number let g:airline#extensions#tabline#fnamecollapse = 1 " /a/m/model.rb let g:airline#extensions#hunks#non_zero_only = 1 " git gutter +" Syntastic +" show list of errors and warnings on the current file +nmap e :Errors +" turn to next or previous errors, after open errors list +nmap n :lnext +nmap p :lprevious + +set statusline+=%#warningmsg# +set statusline+=%{SyntasticStatuslineFlag()} +set statusline+=%* + +" check also when just opened the file +let g:syntastic_check_on_open = 1 +let g:syntastic_always_populate_loc_list = 1 +let g:syntastic_auto_loc_list = 1 +let g:syntastic_enable_signs = 1 + + +" syntastic checker for javascript. +" eslint is the only tool support JSX. +" If you don't need write JSX, you can use jshint. +" And eslint is slow, but not a hindrance +let g:syntastic_javascript_checkers = ['jshint'] +" let g:syntastic_javascript_checkers = ['eslint'] + +" syntastic checker for python. +" let g:syntastic_python_checkers = ["pylint"] +" let g:syntastic_python_checkers = ["flake8"] +let g:syntastic_python_checkers = ['prospector'] + +" don't put icons on the sign column (it hides the vcs status icons of signify) +let g:syntastic_enable_signs = 1 + +" custom icons (enable them if you use a patched font, and enable the previous +" setting) +let g:syntastic_error_symbol = '✗' +let g:syntastic_warning_symbol = '⚠' +let g:syntastic_style_error_symbol = '✗' +let g:syntastic_style_warning_symbol = '⚠' + + " YouCompleteMe -let g:ycm_filetype_blacklist = {} -let g:ycm_key_list_select_completion = [] -let g:ycm_key_list_previous_completion = [] -let g:ycm_key_invoke_completion = "" -let g:ycm_collect_identifiers_from_tags_files = 1 +"let g:ycm_filetype_blacklist = {} +"let g:ycm_key_list_select_completion = [] +"let g:ycm_key_list_previous_completion = [] +"let g:ycm_key_invoke_completion = "" +"let g:ycm_collect_identifiers_from_tags_files = 1 if executable("ag") let g:ackprg = "ag --nogroup --column" diff --git a/020_refracta-tools.sh b/020_refracta-tools.sh index 9c6c450..474552a 100644 --- a/020_refracta-tools.sh +++ b/020_refracta-tools.sh @@ -1,16 +1,22 @@ set +x # get and install refracta stuff # For jessie yad needs to be built from testing/ascii (and gtk3 dep changed in control) -apt-get -y install autotools-dev libgtk2.0-dev pkg-config intltool +#apt-get -y install autotools-dev libgtk2.0-dev pkg-config intltool +apt-get install -y sbuild fakeroot schroot -cd /usr/src -apt-get source yad -YAD_VERSION=$(apt-cache policy yad|sed -n 3p | sed s/:/\\n/g|sed -n 2p| sed s/-/\\n/g | sed -e 's/^[ \t]*//' | sed -n 1p) -sed -i -e s/libgtk-3-dev/libgtk2.0-dev/g /usr/src/yad-${YAD_VERSION}/debian/control -sed -i -e s/gtk3/gtk2/g /usr/src/yad-${YAD_VERSION}/debian/rules -cd /usr/src/yad-${YAD_VERSION} -dpkg-buildpackage -us -uc -b -dpkg -i ../yad_${YAD_VERSION}-1_amd64.deb +cd /usr/src || exit +RELEASE=$(awk -F '/' \{'print $1'\} < /etc/devuan_version | awk '$1=$1') +YAD_VERSION=$(apt-cache policy yad|sed -n 3p | awk -F ':' \{'print $2'\} | awk '$1=$1') +gbp import-dsc -v --allow-unauthenticated http://cdn-fastly.deb.debian.org/debian/pool/main/y/yad/yad_"${YAD_VERSION}".dsc + +sed -i -e s/libgtk-3-dev/libgtk2.0-dev/g /usr/src/yad-"${YAD_VERSION}"/debian/control +sed -i -e s/gtk3/gtk2/g /usr/src/yad-"${YAD_VERSION}"/debian/rules +cd /usr/src/yad || exit +#dpkg-buildpackage -us -uc -b +gbp buildpackage --git-builder=sbuild -A -v -d "${RELEASE}" +dpkg -i ../yad_"${YAD_VERSION}"_amd64.deb + +sudo schroot --end-session --all-sessions # Refractasnapshot 10 introduces support of UEFI bootable iso but grub-efi removes grub-pc #apt-get install -y grub-efi-amd64 @@ -37,6 +43,6 @@ URL_LIST=( \ #for URL in ${URL_LIST[*]}; do printf " %s\n" ${URL}; done #for URL in ${URL_LIST[*]}; do printf " %s\n" ${URL##*/}; done -for URL in ${URL_LIST[*]}; do printf ${URL}; wget -c ${URL} && dpkg -i ./${URL##*/}; done +for URL in ${URL_LIST[*]}; do echo "${URL}"; wget -c "${URL}" && dpkg -i ./"${URL##*/}"; done apt-get -y -f install diff --git a/020_themes.sh b/020_themes.sh index 13a6cda..eeb28fe 100644 --- a/020_themes.sh +++ b/020_themes.sh @@ -1,4 +1,3 @@ apt-get install mate-themes apt-get install albatross-gtk-theme apt-get install blackbird-gtk-theme -apt-get install gtk2-engines-ubuntulooks diff --git a/020_tmux.sh b/020_tmux.sh index 7398cc7..23c3f27 100644 --- a/020_tmux.sh +++ b/020_tmux.sh @@ -1,6 +1,6 @@ -apt-get install tmux -apt-get install tmux-plugin-manager -apt-get install tmuxinator +apt-get install -y tmux +apt-get install -y tmux-plugin-manager +apt-get install -y tmuxinator # https://github.com/Netherdrake/Dotfiles/tree/master/config/tmux # wget -c --directory-prefix ~/.config/tmux/ https://raw.githubusercontent.com/Netherdrake/Dotfiles/master/config/tmux/default.sh diff --git a/020_vim.sh b/020_vim.sh index d530529..543adc8 100644 --- a/020_vim.sh +++ b/020_vim.sh @@ -98,7 +98,7 @@ cat > ~/.Xresources << 'EOF' *color15: #C5C8C6 EOF -cd ~ +cd ~ || exit apt-get install -y git git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim @@ -126,6 +126,7 @@ Plugin 'VundleVim/Vundle.vim' " plugin on GitHub repos Plugin 'tpope/vim-fugitive' +Plugin 'jreybert/vimagit' Plugin 'wincent/command-t' Plugin 'tmhedberg/SimpylFold' Plugin 'vim-scripts/indentpython.vim' @@ -135,10 +136,12 @@ Plugin 'nvie/vim-flake8' Plugin 'jnurmine/Zenburn' Plugin 'w0ng/vim-hybrid' Plugin 'altercation/vim-colors-solarized' -Plugin 'kien/ctrlp.vim' +"Plugin 'kien/ctrlp.vim' +Plugin 'ctrlpvim/ctrlp.vim' "Plugin 'Lokaltog/powerline', {'rtp': 'powerline/bindings/vim/'} Plugin 'vim-airline/vim-airline' Plugin 'vim-airline/vim-airline-themes' +Plugin 'ryanoasis/vim-devicons' Plugin 'will133/vim-dirdiff' Plugin 'jiangmiao/auto-pairs' Plugin 'mhinz/vim-startify' @@ -171,6 +174,7 @@ Plugin 'fisadev/vim-isort' " Automatically sort python imports Plugin 'klen/python-mode' Plugin 'scrooloose/syntastic' Plugin 'scrooloose/nerdcommenter' +Plugin 'sbdchd/neoformat' Plugin 'luochen1990/rainbow' let g:rainbow_active = 1 "0 if you want to enable it later via :RainbowToggle @@ -185,6 +189,47 @@ filetype plugin indent on " required filetype plugin on . +"--------------------------------------- +" Syntastic + +" show list of errors and warnings on the current file +nmap e :Errors +" turn to next or previous errors, after open errors list +nmap n :lnext +nmap p :lprevious + +set statusline+=%#warningmsg# +set statusline+=%{SyntasticStatuslineFlag()} +set statusline+=%* + +" check also when just opened the file +let g:syntastic_check_on_open = 1 +let g:syntastic_always_populate_loc_list = 1 +let g:syntastic_auto_loc_list = 1 +let g:syntastic_enable_signs = 1 + +" syntastic checker for javascript. +" eslint is the only tool support JSX. +" If you don't need write JSX, you can use jshint. +" And eslint is slow, but not a hindrance +let g:syntastic_javascript_checkers = ['jshint'] +" let g:syntastic_javascript_checkers = ['eslint'] + +" syntastic checker for python. +" let g:syntastic_python_checkers = ["pylint"] +" let g:syntastic_python_checkers = ["flake8"] +let g:syntastic_python_checkers = ['prospector'] + +" don't put icons on the sign column (it hides the vcs status icons of signify) +let g:syntastic_enable_signs = 1 + +" custom icons (enable them if you use a patched font, and enable the previous +" setting) +let g:syntastic_error_symbol = '✗' +let g:syntastic_warning_symbol = '⚠' +let g:syntastic_style_error_symbol = '✗' +let g:syntastic_style_warning_symbol = '⚠' +"---------------------------------------- if has('gui_running') set background=dark @@ -202,6 +247,7 @@ let g:airline#extensions#tabline#enabled = 1 + " Nerdcommenter customizations " Add spaces after comment delimiters by default let g:NERDSpaceDelims = 1 @@ -275,3 +321,4 @@ apt-get install -y python-dev python3-dev #apt-get install -y python-pip #pip install jedi apt-get install -y vim-python-jedi +apt-get install -y prospector diff --git a/020_waterfox.sh b/020_waterfox.sh new file mode 100644 index 0000000..0ec5c19 --- /dev/null +++ b/020_waterfox.sh @@ -0,0 +1,16 @@ +#!/bin/bash +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 +EOF + +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 - + +apt-get update + +apt-get install -y waterfox + diff --git a/020_zsh-vim_bindings.sh b/020_zsh-vim_bindings.sh deleted file mode 100644 index 8f4025e..0000000 --- a/020_zsh-vim_bindings.sh +++ /dev/null @@ -1,93 +0,0 @@ -# http://www.zshwiki.org/home/zle/vi-mode -# -echo "This script is very broken, and squashes .vimrc EXITING - FIXME" -exit -cat > ~/.vimrc <<'EOF' -" Set vi command-line mode -bindkey -v - -" Use right prompt to display vi mode. -precmd() { - RPROMPT="" -} -zle-keymap-select() { - RPROMPT="" - [[ $KEYMAP = vicmd ]] && RPROMPT="(CMD)" - () { return $__prompt_status } - zle reset-prompt -} -zle-line-init() { - typeset -g __prompt_status="$?" -} -zle -N zle-keymap-select -zle -N zle-line-init - -" Vim bindings. -bindkey -a 'gg' beginning-of-buffer-or-history -bindkey -a 'g~' vi-oper-swap-case -bindkey -a G end-of-buffer-or-history - -" In Vim backspace doesn't stop at the point where you started insert mode: -bindkey '^?' backward-delete-char -bindkey '^H' backward-delete-char - -" -bindkey '^G' what-cursor-position - -" Text Objects -" Some are provided as shell functions so need to be manually enabled. select-bracketed which selects -" text delimited by brackets and select-quoted which selects text delimited by quote characters. -" The following binds them to key combinations such as i" a( in both the visual and viopp keymaps. -autoload -U select-bracketed select-quoted -zle -N select-bracketed -zle -N select-quoted - for km in viopp visual; do - bindkey -M $km -- '-' vi-up-line-or-history - for c in {a,i}"${(s..):-\'\"\`\|,./:;-=+@}"; do - bindkey -M $km $c select-quoted - done - for c in {a,i}${(s..):-'()[]{}<>bB'}; do - bindkey -M $km $c select-bracketed - done -done - -" Clipboard integration using xclip -[[ -n $DISPLAY ]] && (( $+commands[xclip] )) && { - - function cutbuffer() { - zle .$WIDGET - echo $CUTBUFFER | xclip - } - - zle_cut_widgets=( - vi-backward-delete-char - vi-change - vi-change-eol - vi-change-whole-line - vi-delete - vi-delete-char - vi-kill-eol - vi-substitute - vi-yank - vi-yank-eol - ) - for widget in $zle_cut_widgets - do - zle -N $widget cutbuffer - done - - function putbuffer() { - zle copy-region-as-kill "$(xclip -o)" - zle .$WIDGET - } - - zle_put_widgets=( - vi-put-after - vi-put-before - ) - for widget in $zle_put_widgets - do - zle -N $widget putbuffer - done -} -EOF diff --git a/050_remove_avahi.sh b/050_remove_avahi.sh index 13ed697..58479bb 100644 --- a/050_remove_avahi.sh +++ b/050_remove_avahi.sh @@ -1,6 +1,8 @@ # removing any more of avahi need rebuilding of libpurple libgnomevfs libgnome2 bash -c "update-rc.d avahi-daemon disable" -apt-get -y remove --purge cups-browsed -apt-get -y remove --purge avahi-autoipd libavahi-common-data libavahi-common3 avahi-daemon libavahi-glib1 libavahi-client3 +apt-get -y remove --purge cups-browsed avahi-autoipd + +echo " This stops the avahi daemon but the dependencies of any of the libavahi reach throught to just about all desktop packages." +#apt-get -y remove --purge libavahi-common-data libavahi-common3 avahi-daemon libavahi-glib1 libavahi-client3 diff --git a/050_remove_policykit-1.sh b/050_remove_policykit-1.sh index 0641cd8..5115b02 100644 --- a/050_remove_policykit-1.sh +++ b/050_remove_policykit-1.sh @@ -1,2 +1,12 @@ # From the people who thought bash scripts in init.d were too complicated we get javascript snipits and xml based configuration files to set permissions, just say no. apt-get -y remove --purge policykit-1 + +# This does a number of good things, removing: +# hplip +# policykit-1 +# synaptic +# colord +# policykit-1-gnome +# packagekit +# packagekit-tools +# printer-driver-postscript-hp diff --git a/extract_chroot_image.sh b/extract_chroot_image.sh new file mode 100644 index 0000000..71e38f6 --- /dev/null +++ b/extract_chroot_image.sh @@ -0,0 +1,33 @@ +# Extract an image from devuan released images for use in mobile phone chroots. + +# Fetch the image, for Samsung S4 we need a armhf image. +#https://files.devuan.org/devuan_jessie/embedded/devuan_jessie_1.0.0_armhf_sunxi.img.xz +#https://files.devuan.org/devuan_jessie/embedded/devuan_jessie_1.0.0_armhf_raspi2.img.xz +#https://files.devuan.org/devuan_jessie/embedded/devuan_jessie_1.0.0_armhf_odroidxu.img.xz +#https://files.devuan.org/devuan_jessie/embedded/devuan_jessie_1.0.0_armhf_n900.img.xz +#https://files.devuan.org/devuan_jessie/embedded/devuan_jessie_1.0.0_armhf_chromeveyron.img.xz +#https://files.devuan.org/devuan_jessie/embedded/devuan_jessie_1.0.0_armhf_chromeacer.img.xz + +FILE_URL=https://files.devuan.org/devuan_jessie/embedded +XZIMAGE=$1|devuan_jessie_1.0.0_armhf_sunxi.img.xz +IMAGE=${XZIMAGE%\.*} + +wget -c ${FILE_URL}/${XZIMAGE} + +# uncompress +unxz ${XZIMAGE} + +# Mount the partitions +apt-get install -y kpartx + + kpartx -a -v ${IMAGE} + +TMP_MNT=/tmp/kpartx-mnt +mkdir -p ${TMP_MNT} + +mount /dev/mapper/loop0p2 ${TMP_MNT} + +tar czvf linux-rootfs.tar.gz -C ${TMP_MNT} . + +umount ${TMP_MNT} +rm ${IMAGE} diff --git a/sbuild-devuan.sh b/sbuild-devuan.sh old mode 100644 new mode 100755 index 9252aa8..2914161 --- a/sbuild-devuan.sh +++ b/sbuild-devuan.sh @@ -1,15 +1,16 @@ #!/bin/bash + LOGNAME=${USER} -RELEASE=$(cat /etc/devuan_version) +RELEASE=$(awk -F '/' \{'print $1'\} < /etc/devuan_version | awk '$1=$1') KEYRING=/usr/share/keyrings/devuan-archive-keyring.gpg -INCLUDE="eatmydata,ccache,gnupg" +INCLUDE="eatmydata,ccache,gnupg,debhelper,autotools-dev" MIRROR=http://pkgmaster.devuan.org/merged apt-get install -y sbuild mkdir -p /root/.gnupg # To work around #792100 sbuild-update --keygen # see #801798 -sbuild-adduser ${LOGNAME} -usermod -g sbuild ${LOGNAME} -$(newgrp sbuild) +sbuild-adduser "${LOGNAME}" +usermod -g sbuild "${LOGNAME}" +#$(newgrp sbuild) -sbuild-createchroot --keyring=${KEYRING} --include=${INCLUDE} ${RELEASE} /srv/chroot/${RELEASE}-amd64-sbuild ${MIRROR} +sbuild-createchroot --keyring="${KEYRING}" --include="${INCLUDE}" "${RELEASE}" /srv/chroot/"${RELEASE}"-amd64-sbuild "${MIRROR}"