Raw notes about ~/.xprofile
script.
Upstream DM which executes ~/.xprofile file in Xsession script:
- GDM (Gnome): see
Xsession.in
- KDM (KDE 4): see
genkdmconf.c
apply plugin: 'java' | |
apply plugin: 'scala' | |
// For those using Eclipse or IntelliJ IDEA | |
apply plugin: 'eclipse' | |
apply plugin: 'idea' | |
def findPlay20(){ | |
def pathEnvName = ['PATH', 'Path'].find{ System.getenv()[it] != null } | |
for(path in System.getenv()[pathEnvName].split(File.pathSeparator)){ | |
for(playExec in ['play.bat', 'play.sh', 'play']){ |
#!/bin/bash | |
# node.js using PPA (for statsd) | |
sudo apt-get install python-software-properties | |
sudo apt-add-repository ppa:chris-lea/node.js | |
sudo apt-get update | |
sudo apt-get install nodejs npm | |
# Install git to get statsd | |
sudo apt-get install git |
#!/bin/bash -ex | |
# Paste this into ssh | |
# curl -sL https://gist.github.com/andsens/2913223/raw/bootstrap_homeshick.sh | tar -xzO | /bin/bash -ex | |
# When forking, you can get the URL from the raw (<>) button. | |
### Set some command variables depending on whether we are root or not ### | |
# This assumes you use a debian derivate, replace with yum, pacman etc. | |
aptget='sudo apt-get' | |
chsh='sudo chsh' |
# A downloader middleware automatically to redirect pages containing a rel=canonical in their contents to the canonical url (if the page itself is not the canonical one), | |
from scrapy.contrib.linkextractors.sgml import SgmlLinkExtractor | |
from scrapy.utils.url import url_is_from_spider | |
from scrapy.http import HtmlResponse | |
from scrapy import log | |
class RelCanonicalMiddleware(object): | |
_extractor = SgmlLinkExtractor(restrict_xpaths=['//head/link[@rel="canonical"]'], tags=['link'], attrs=['href']) |
/* bad indentation is NetBeans' fault, camelCase is Propel's fault */ | |
var retrieveTeachers = function(query, process) { | |
// let them be json | |
var transformTeachers = function(teachers) { | |
return $.map(teachers, function(teacher) { | |
return { | |
id: teacher.Id, | |
FullName: (teacher.Name + ' ' + teacher.Surname), | |
// these functions allows Bootstrap typehead to use this item in places where it was expecting a string | |
toString: function() { |
#!/usr/bin/python | |
# | |
# Stars all the repos for an organization. | |
# | |
import sys | |
import urllib2 | |
import json | |
import os.path |
(function () { | |
function giphy(word, callback) { | |
var xhr = new XMLHttpRequest(); | |
var url = 'https://api.giphy.com/v1/gifs/translate?rating=pg-13&api_key=dc6zaTOxFJmzC&s=' + encodeURIComponent(word); | |
xhr.open('GET', url); | |
xhr.onreadystatechange = function(e) { | |
if(xhr.readyState === 4) { | |
var url = JSON.parse(e.target.responseText).data.images.fixed_height.url; | |
callback(url); | |
} |
#Generate master.key and secret | |
MAGIC="::::MAGIC::::" | |
mkdir -p /var/jenkins_home/secrets | |
openssl rand -hex 128 > /var/jenkins_home/secrets/master.key | |
openssl dgst -sha256 -binary /var/jenkins_home/secrets/master.key > /tmp/master.hashed | |
HEX_MASTER_KEY=`head -c 16 /tmp/master.hashed | xxd -l 16 -p` | |
openssl rand 259 > /tmp/base | |
echo $MAGIC >> /tmp/base | |
openssl enc -aes-128-ecb -in /tmp/base -K $HEX_MASTER_KEY -out /var/jenkins_home/secrets/hudson.util.Secret |
# i3status configuration file. | |
# see "man i3status" for documentation. | |
# It is important that this file is edited as UTF-8. | |
# The following line should contain a sharp s: | |
# ß | |
# If the above line is not correctly displayed, fix your editor first! | |
general { | |
colors = true |