Skip to content

Instantly share code, notes, and snippets.

View martinec's full-sized avatar
🚀
Turning data into Knowledge

Cristian Martinez martinec

🚀
Turning data into Knowledge
View GitHub Profile
@martinec
martinec / .gitignore.local for gitignore.io
Last active May 11, 2021 14:19
.gitignore.local for gitignore.io
git config --global alias.ignore-create '!gi() { \
if [ $# -eq 0 ]; then \
echo "Usage: git ignore-create list-item,...\n" ;\
echo "Avalaible list items:" ;\
curl -sL "https://www.gitignore.io/api/list" | tr -d "\n" ;\
echo "" ;\
else \
echo "# DO NOT EDIT THIS FILE" ;\
echo "# Put your local changes on .gitignore.local, then\n" ;\
echo "# To update type: git ignore-update" ;\
@martinec
martinec / Dealing with issues.md
Last active April 21, 2017 16:47 — forked from jancborchardt/Dealing with issues.md
Dealing with issues

Dealing with issues

Try to reproduce issues

Go through the new issues and try to reproduce them. It’s important to get additional info, logs, and test if an issue occurs on different platforms. That helps us identify the source of the problem.

Triage issues

  • if there’s more info needed, ask the reporter to use the issue template
  • assign relevant labels
@martinec
martinec / synctex.py
Created March 3, 2017 03:45
SyncTeX between LaTeX and PDF with Geany and Zathura
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Synchronize between LaTeX and PDF with Geany and Zathura
# This plugin add both a new menu item under the Tools menu
# and a keyboard shortcut to launch Zathura using its SyncTeX
# forward search feature. A simpler approach would be to add
# a custom build command (Build > Set Build Commands), however
# this lack of a key binding and current column information
# To make this plugin work, you must:
# compile (make WITH_SYNCTEX=1) and install zathura from https://git.pwmt.org/pwmt/zathura.git
@martinec
martinec / config.json
Created November 19, 2016 01:01
Disable Nylas N1 non-free built-in plugins
"disabledPackages": [
"activity-list",
"composer-mail-merge",
"composer-scheduler",
"link-tracking",
"open-tracking",
"send-later",
"send-reminders",
"thread-sharing"
],

Keybase proof

I hereby claim:

  • I am martinec on github.
  • I am martinec (https://keybase.io/martinec) on keybase.
  • I have a public key ASB8puwS5G3y3WeKwmMNIVv_e5t6JkfJquGJ0Y2VrwDsRgo

To claim this, I am signing this object:

@martinec
martinec / TLS206_ASCII
Last active May 13, 2016 00:16
Parse plain FILE(s) and load them into TLS206_ASCII PATSTAT table
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
-- --------------------------------------------------------
--
@martinec
martinec / Makefile
Last active June 2, 2021 07:45
Batch convert a favicon.svg file in a favicon.ico image (different sizes)
# Batch convert a favicon.svg file in a favicon.ico image (different sizes)
# This makefile uses inkscape, convert, optipng and advpng command line tools
# type make favicon
# Cristian Martinez
all: icons
# Input SVG images without extensions
IMAGES = favicon
# Output PNG sizes
@martinec
martinec / gitignore.io.sh
Last active August 29, 2015 14:06
simple gitignore.io shell wrapper
#!/bin/bash
# =============================================================================
# gitignore.io.sh - simple gitignore.io shell wrapper
# https://gist.github.com/martinec/ba3012e1a5abf954f977
# =============================================================================
# Copyright (C) 2014
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
@martinec
martinec / getallmethods-snnipet.js
Last active August 29, 2015 14:01
Display all methods in a JavaScript object
/**
* Enumerate all methods in a Javascript object (ES5)
* @source http://stackoverflow.com/a/2946616
*/
function getAllMethods(object) {
return Object.getOwnPropertyNames(object).filter(function(property) {
return typeof object[property] == 'function';
});
}
@martinec
martinec / updateobject-snnipet.js
Last active August 29, 2015 14:01
Updating javascript object property
function update ( first, second ) {
for (var key in second) {
if (first.hasOwnProperty(key)) {
first[ key ] = second[ key ];
}
}
return first;
}