Skip to content

Instantly share code, notes, and snippets.

View ademaro's full-sized avatar
🔥
in the flow...

Ademaro ademaro

🔥
in the flow...
View GitHub Profile
@ademaro
ademaro / import-github-labels.js
Last active February 21, 2024 13:45 — forked from Isaddo/import-github-labels.js
import github labels via console command
/*
Go on your labels page (https://github.com/user/repo/labels)
Edit the following label array
or
Use this snippet to export github labels (https://gist.github.com/MoOx/93c2853fee760f42d97f)
and replace it
Paste this script in your console
Press Enter!!
@ademaro
ademaro / index.js
Last active September 27, 2020 14:17 — forked from MoOx/index.js
Export/import github labels
// go on you labels pages
// eg https://github.com/cssnext/cssnext/labels
// paste this script in your console
// copy the output and now you can import it using https://github.com/popomore/github-labels !
var labels = [];
[].slice.call(document.querySelectorAll(".js-label-link"))
.forEach(function(element) {
labels.push({
name: element.textContent.trim(),
@ademaro
ademaro / gulpfile.js
Created March 16, 2018 06:17 — forked from demisx/gulpfile.js
Gulp 4 gulpfile.js
// Gulp 4
var gulp = require('gulp');
var using = require('gulp-using');
var grep = require('gulp-grep');
var changed = require('gulp-changed');
var del = require('del');
var coffee = require('gulp-coffee');
var less = require('gulp-less');
var coffeelint = require('gulp-coffeelint');
var sourcemaps = require('gulp-sourcemaps');
@ademaro
ademaro / tmux-cheatsheet.markdown
Created July 10, 2017 21:32 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@ademaro
ademaro / tmux.md
Created August 2, 2014 04:13 — forked from andreyvit/tmux.md

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

remap prefix to Control + a

server {
listen 80;
server_name domain.ru;
rewrite ^(.*)$ http://www.domain.ru$1 permanent;
}
server {
listen 80;
server_name www.domain.ru;
@ademaro
ademaro / ocstore.conf
Created November 22, 2013 19:47
templates/ocstore
location = /sitemap.xml {
rewrite ^ /index.php?route=feed/google_sitemap;
}
location = /googlebase.xml {
rewrite ^ /index.php?route=feed/google_base;
}
location /download/ {
rewrite ^ /index.php?route=error/not_found;
@ademaro
ademaro / php.conf
Created November 22, 2013 19:45
templates/php
index index.php;
location / {
try_files $uri $uri/ /index.php?q=$uri&$args;
}
location ~ \.php$ {
#fastcgi_pass 127.0.0.1:9000;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;

tmux cheatsheet

As configured in my dotfiles.

start new:

tmux

start new with session name:

@ademaro
ademaro / menu.py
Created October 20, 2012 16:08
converting data from sqlite3
id|parent|alias
---------------
1 |0 |first
2 |0 |second
3 |1 |sub-first1
4 |1 |sub-first2
5 |3 |sub-sub-first
6 |5 |last
---------------------------------
I HAVE || I WANT