Skip to content

Instantly share code, notes, and snippets.

View LucaColonnello's full-sized avatar
👋
Come say hello on Twitter!

Luca Colonnello LucaColonnello

👋
Come say hello on Twitter!
View GitHub Profile
@LucaColonnello
LucaColonnello / vsc-settings.py
Created September 10, 2020 18:11 — forked from wonderbeyond/vsc-settings.py
script to export vsc settings
#!/usr/bin/env python3
from os import path
import tempfile
import subprocess
import datetime as dt
import click
@click.group()
def cli():

How Fast if Git?

The web is full of benchmarks showing the supernatural speed of Git even with very big repositories, but unfortunately they use the wrong variable. Size is not important, but the number of files in the repository really is!

Why is that? Well, that's because Git works in a very different way compared to Synergy. You don't have to checkout a file in order to edit it; Git will do that for you automatically. But at what price?

The price is that for every Git operation that requires to know which files changed (git status, git commmit, etc etc) an lstat() call will be executed for every single file

Wow! So how does that perform on a fairly large repository? Let's find out! For this example I will use an example project, which has 19384 files in 1326 folders.

@LucaColonnello
LucaColonnello / projects.graphql
Created January 10, 2020 12:26 — forked from dahlbyk/projects.graphql
GraphQL to fetch GitHub Projects+Columns+Cards with issue/PR detail for a specific repo.
{
search(type: REPOSITORY, query: "org:huboard-testing spooky-octo-pug", first: 1) {
edges {
node {
__typename
... on Repository {
owner {
id
}
name
@LucaColonnello
LucaColonnello / git-delete-local-tag.sh
Created November 12, 2018 13:48 — forked from canhnt/git-delete-local-tag.sh
Delete local tags that do not exist in remote
git fetch --prune origin "+refs/tags/*:refs/tags/*"
@LucaColonnello
LucaColonnello / Sort.jsx
Created March 9, 2016 21:30 — forked from gianmarcotoso/Sort.jsx
React Sort HoC
import React from 'react';
import { Component } from 'react';
let Sort = Sortable => class extends Component {
constructor(props) {
super(props);
this.state = {
items: []
}
@LucaColonnello
LucaColonnello / Filter.jsx
Created March 9, 2016 21:29 — forked from gianmarcotoso/Filter.jsx
React Filter HoC
import React from 'react';
import { Component } from 'react';
let Filter = Filterable => class extends Component {
constructor(props) {
super(props);
this.state = {
items: props.items
};
@LucaColonnello
LucaColonnello / languages.json
Created December 11, 2015 11:25 — forked from abiank/languages.json
languages.json
/**
* @author Phil Teare
* using wikipedia data
*/
isoLangs = {
"ab":{
"name":"Abkhaz",
"nativeName":"аҧсуа"
},
"aa":{
@LucaColonnello
LucaColonnello / MDN_Languages.js
Created December 11, 2015 10:59 — forked from ethertank/MDN_Languages.js
MDN_Languages
var MDN_Languages_AlphabetOrder = {
"ar" : "عربي",
"ca" : "català",
"cs" : "Čeština",
"de" : "Deutsch",
"el" : "Ελληνικά",
"en-us" : "English (US)",
"es" : "Español",
"fa" : "فارسی",
"fi" : "suomi",
@LucaColonnello
LucaColonnello / README.markdown
Created December 11, 2015 10:56 — forked from marijn/README.markdown
List of nationalities in YAML, CSV and TXT format

List of nationalities

It's time someone compiled a list of nationalities to use within a web application. This gist attempts to make a first move at that.

##List of countries

I've also compiled a list of countries

@LucaColonnello
LucaColonnello / README.markdown
Created December 11, 2015 09:22 — forked from marijn/README.markdown
List of countries in YAML, CSV and TXT format

#List of countries

It's time someone compiled a list of countries to use within a web application. This gist attempts to make a first move at that.

List of nationalities

I've also compiled a list of nationalities