This file contains 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 | |
mkdir ~/local | |
mkdir ~/build | |
export TARGET_DIR="$HOME/local" | |
cd ~/build | |
hg clone http://hg.debian.org/hg/pkg-vim/vim | |
cd vim |
This file contains 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
"""Contours with overlap control. | |
This script generates widely spaced black contours, with a gray patch in a | |
subregion where more finely-spaced colored contours are visible. The gray | |
patch covers the black contours. | |
""" | |
import numpy as np | |
import matplotlib.mlab as mlab | |
from matplotlib.patches import Rectangle |
This file contains 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
# basic .muttrc for use with Gmail | |
# Change the following six lines to match your Gmail account details | |
set imap_user = "username@gmail.com" | |
set imap_pass = "" | |
set smtp_url = "smtp://username@smtp.gmail.com:587/" | |
set smtp_pass = "" | |
set from = "username@gmail.com" | |
set realname = "Firstname Lastname" | |
# |
This file contains 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
set imap_user = 'user@gmail.com' | |
set imap_pass = 'pass' | |
set spoolfile = imaps://imap.gmail.com:993/INBOX | |
set folder = imaps://imap.gmail.com:993 | |
set record="imaps://imap.gmail.com/[Gmail]/Sent Mail" | |
set postponed=”imaps://imap.gmail.com/[Gmail]/Drafts” | |
set message_cachedir=”~/.mutt/cache/bodies” | |
set certificate_file=~/.mutt/certificates | |
set smtp_url = "smtp://user@smtp.gmail.com:587/" |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
import numpy as np | |
import matplotlib.pyplot as plt | |
import cartopy.crs as ccrs | |
import iris | |
from iris.coord_systems import GeogCS | |
from iris.cube import Cube | |
This file contains 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
""""Create "The Matrix" of binary numbers scrolling vertically in your terminal. | |
original code adapted from juancarlospaco: | |
- http://ubuntuforums.org/showpost.php?p=10306676 | |
Inspired by the movie: The Matrix | |
- Corey Goldberg (2013) | |
Requires: |
This file contains 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 | |
# i3 thread: https://faq.i3wm.org/question/150/how-to-launch-a-terminal-from-here/?answer=152#post-id-152 | |
# Inspired by https://gist.github.com/viking/5851049 but with support for tmux | |
CWD='' | |
# Get window ID | |
ID=$(xdpyinfo | grep focus | cut -f4 -d " ") | |
# Get PID of process whose window this is |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
BLACK_COLOR = "#000000" | |
WHITE_COLOR = "#FFFFFF" | |
def get_contrast_color(background_color: str) -> str: | |
""" | |
Util function to determine what's the best color between black or white to choose for a text | |
depending on the background color given in parameter. | |
Based on algorythm from WCAG 2.0 explained here : https://www.w3.org/TR/WCAG20-TECHS/G18.html#G18-tests | |
:param background_color: the background color in HEX format (eg: #9D412B) |
OlderNewer