Skip to content

Instantly share code, notes, and snippets.

View coline-carle's full-sized avatar

Coline Carle coline-carle

View GitHub Profile
@-moz-document domain("lemonde.fr") {
.services, .vous, .audience, #teaser_article .bordt1, #header-page, #footer, #footer-page, #header, #en_ce_moment, #footer_services, #ultimedia_wrapper, .fb_iframe_widget, .toolbar, iframe, .conteneur_barre_outils, .meme_sujet, .liste_reactions {
display: none !important;
}
.container_18 .grid_10 {
width: 700px;
margin-left: 60px;
}
.container_18 .grid_12 {
width: 100%;
@imranismail
imranismail / queue.ex
Last active April 3, 2021 21:12
Process native queue with backpressure using Erlang's :queue and Elixir's GenStage spawning a Process for each job in queue
# Elixir :queue wrapper with modified behavior for empty queues to mimic Enumerable module in Elixir
defmodule Queue do
def insert(queue, item), do: :queue.in(item, queue)
def insert_last(queue, item), do: :queue.in_r(item, queue)
def member?(queue, item), do: :queue.member(item, queue)
def filter(queue, fun), do: :queue.filter(fun, queue)
@zcmarine
zcmarine / remap_capslock.lua
Created March 28, 2017 15:35
Hammerspoon capslock remapping: tap to Escape, hold in chord for Control
-- Inspired by https://github.com/jasoncodes/dotfiles/blob/master/hammerspoon/control_escape.lua
-- You'll also have to install Karabiner Elements and map caps_lock to left_control there
len = function(t)
local length = 0
for k, v in pairs(t) do
length = length + 1
end
return length
end
@schmich
schmich / config.bat
Last active July 5, 2023 03:36
Forward external connections to Docker on Windows
REM In admin prompt
REM Ensure web server/application is listening on all interfaces (0.0.0.0)
netsh interface portproxy add v4tov4 listenaddress=0.0.0.0 listenport=80 connectaddress=10.0.75.2 connectport=80
netsh advfirewall firewall add rule name="App" dir=in action=allow protocol=TCP localport=80 remoteport=80
netsh interface portproxy show v4tov4
netsh advfirewall firewall show rule "App"
netsh interface portproxy delete v4tov4 listenaddress=0.0.0.0 listenport=80
netsh advfirewall firewall del rule name="App"
@arbelt
arbelt / init.lua
Created October 2, 2016 20:55
Hammerspoon config to send escape on short ctrl press
ctrl_table = {
sends_escape = true,
last_mods = {}
}
control_key_timer = hs.timer.delayed.new(0.15, function()
ctrl_table["send_escape"] = false
-- log.i("timer fired")
-- control_key_timer:stop()
end
@leonelgalan
leonelgalan / codeclimate.sh
Created February 18, 2016 15:23
Setting up Code Climate with Docker/Docker Machine
: Please update Homebrew often and make sure "Your system is ready to brew."
brew update && brew doctor
: Install VirtualBox
brew tap caskroom/cask
brew cask install virtualbox
: Install/Setup Docker
brew install docker
brew install docker-machine
@andyshinn
andyshinn / Dockerfile
Created December 24, 2015 19:07
BusyBox cron container example
FROM gliderlabs/alpine:3.3
COPY myawesomescript /bin/myawesomescript
COPY root /var/spool/cron/crontabs/root
RUN chmod +x /bin/myawesomescript
CMD crond -l 2 -f
@vt0r
vt0r / GnuPG-2.2.md
Last active February 13, 2024 09:03 — forked from mattrude/GnuPG-2.1.md
Build/install instructions for GnuPG 2.2.x on Ubuntu and similar distros (formerly for 2.1.x)

GnuPG 2.2.x Build Instructions

Below are my build instructions for GnuPG 2.2.10, released on August 30th, 2018. These instructions are built for a headless Ubuntu 18.04 LTS server (and have also been tested on Ubuntu 14.04/16.04).

If you prefer, you may use the below install script to install GnuPG 2.2.x by running the following commands:

curl -OL "https://gist.githubusercontent.com/vt0r/a2f8c0bcb1400131ff51/raw/e0d2011d7b89bfe5b83c3f29f21949fb21354dd9/install-gnupg22.sh" && sudo -H bash ./install-gnupg22.sh

Install the needed dependencies

@renoirb
renoirb / README.md
Last active October 4, 2017 01:05
Development environment overriding prod for manifest development

Workspace files:

workspace/salt-master/
  - Vagrantfile
  - etc/
    - salt/ 
      - master.d/
        - remotes.conf
 - NOTE: anything else that I want in ALL environments)
anonymous
anonymous / MenuItem Insert
Created December 24, 2011 21:37
Wow Lua Code for inserting menu items into dropdowns
This is what I am using atm.
function MG:UnitPopup_HideButtons()
local k
local dropdownMenu = UIDROPDOWNMENU_INIT_MENU
for index, value in ipairs(UnitPopupMenus[UIDROPDOWNMENU_MENU_VALUE] or UnitPopupMenus[dropdownMenu.which]) do
if value == "METAGUILD_INVITE" then
k = (not self:CanInvite(dropdownMenu.name) or dropdownMenu.name == UnitName("player")) and 0 or 1
UnitPopupShown[UIDROPDOWNMENU_MENU_LEVEL][index] = k