http://cradylab.com/apm-broken-usb-rescue/
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;;; common-mode-line.el --- mode-line common for all windows. | |
;; Copyright (C) 2017 Constantin Kulikov | |
;; | |
;; Author: Constantin Kulikov (Bad_ptr) <[email protected]> | |
;; Version: 0.1 | |
;; Package-Requires: () | |
;; Date: 2017/01/24 16:22:13 | |
;; License: GPL either version 3 or any later version | |
;; Keywords: frames, windows, mode-line, convenience |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(with-eval-after-load "persp-mode" | |
(with-eval-after-load "helm-mode" | |
(defvar helm-mini-tail-sources (cdr helm-mini-default-sources)) | |
(defvar helm-persp-completing-read-handlers | |
'((switch-to-buffer . helm-persp-buffer-list-bridge) | |
(kill-buffer . helm-persp-buffer-list-bridge) | |
(persp-kill-buffer . helm-persp-buffer-list-bridge) | |
(persp-temporarily-display-buffer . helm-persp-buffer-list-bridge) | |
(persp-add-buffer . helm-persp-buffer-list-bridge) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if pidof emacs &> /dev/null; then | |
echo "$1" >> /tmp/emacs-files-to-find | |
else | |
emacs "$1" | |
fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
scriptencoding utf-8 | |
set nocompatible | |
"Basic Settings {{{1 | |
" Encoding {{{2 | |
set encoding=utf-8 | |
set termencoding=utf-8 | |
set fileencoding=utf-8 | |
" Text Wrapping {{{2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
xkbcomp -I$HOME/.xkb/ ~/.xkb/keymap/mykbd $DISPLAY & |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from ctypes import * | |
X11 = cdll.LoadLibrary("libX11.so.6") | |
display = X11.XOpenDisplay(None) | |
X11.XkbLockModifiers(display, c_uint(0x0100), c_uint(2), c_uint(0)) | |
X11.XCloseDisplay(display) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# | |
# Test if the computer is running on line power | |
# Exit status: | |
# - 0 (true) System is on AC power | |
# - 1 (false) System is not on AC power | |
# | |
# NOTE: Batteries are not good indicators unless we also check their type, | |
# as some peripherals have batteries. | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bind '"\e[A":history-search-backward' | |
bind '"\e[B":history-search-forward' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;;; company-go.el --- company-mode backend for Go (using gocode) | |
;;; Code: | |
(eval-when-compile | |
(require 'cl) | |
(require 'company)) | |
(defun company-go--invoke-autocomplete () | |
(let ((temp-buffer (generate-new-buffer "*gocode*"))) |
NewerOlder