Skip to content

Instantly share code, notes, and snippets.

@ahmedelgabri
ahmedelgabri / Sublime Text command log
Created September 21, 2013 19:19
Log Sublime Text command in the console, very helpful when trying to figure out command you want to create shortcuts for.
sublime.log_commands(True)
@martijnvermaat
martijnvermaat / gitlab-ipython-notebook.md
Last active May 8, 2023 00:53
View IPython notebooks in GitLab

Viewing IPython notebooks in GitLab

GitLab is open source software to collaborate on code (a GitHub clone to run on your own server). Clicking a blob (a file in a repository) in GitLab shows a nice rendering if GitLab supports the file type (e.g., images, Markdown documents), or its content as plain text otherwise. The patch described here adds support to GitLab for rendering IPython notebooks (.ipynb files).

@staltz
staltz / introrx.md
Last active July 19, 2024 22:21
The introduction to Reactive Programming you've been missing
apt-get install python2.7-dev python2.7
apt-get build-dep gdb
apt-get source gdb
sed -i -E "s|python3|/usr/bin/python2.7|" debian/rules
dpkg-buildpackage -uc -us -j8
dpkg-install ../*.deb
@moschlar
moschlar / README.md
Last active March 25, 2019 05:01
Build and install ShareLaTeX in Ubuntu 14.04 LTS

Since the official ShareLaTeX documentation is primarily written with Ubuntu 12.04 LTS in mind, I tried to re-build the provided .deb from scratch using Ubuntu 14.04 TLS with the least amount of non-standard or non-packaged software.

Here are all the steps that were required (with sudo since Ubuntu doesn't want you to be root).

First, install lots of packages - note that no additional repositories are required! (Dependencies):

$ sudo apt-get update
$ sudo apt-get install git build-essential curl python-software-properties zlib1g-dev zip unzip
$ sudo apt-get install ruby-dev
$ sudo apt-get install nodejs npm
Go to: chrome://settings/searchEngines
Add a new search engine with the following settings
Gif | Gif | https://www.google.com/search?q=%s&tbm=isch&tbs=itp:animated
Type gif in the address bar press TAB and enter your search query
version: '2'
services:
postgresql:
image: sameersbn/postgresql:9.4-22
restart: always
environment:
- DB_USER=gitlab
- DB_PASS=geheim
- DB_NAME=gitlabhq_production
server {
access_log /var/log/nginx/gitlab_gitlab.log;
error_log /var/log/nginx/gitlab_gitlab.error.log;
listen 80;
server_name git.domain.de;
return 301 https://$server_name$request_uri; # enforce https
}
server {
@udkyo
udkyo / Dockerfile
Last active May 1, 2024 12:51
Basic container for X11 forwarding goodness
FROM ubuntu
RUN apt update \
&& apt install -y firefox \
openssh-server \
xauth \
&& mkdir /var/run/sshd \
&& mkdir /root/.ssh \
&& chmod 700 /root/.ssh \
&& ssh-keygen -A \
&& sed -i "s/^.*PasswordAuthentication.*$/PasswordAuthentication no/" /etc/ssh/sshd_config \
@ryands
ryands / docker-compose.yml
Created August 9, 2018 00:19
gitlab-ce omnibus docker behind a local nginx reverse proxy (letsencrypt ssl termination at local nginx)
version: '3'
services:
gitlab:
image: gitlab/gitlab-ce:latest
hostname: gitlab.example.com
environment:
GITLAB_OMNIBUS_CONFIG: |
external_url 'https://gitlab.example.com/'
nginx['listen_port'] = 80
nginx['listen_https'] = false