git config --global alias.tree "log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative"
git tree
* c3aee36 - (HEAD -> master, tag: DAY01, origin/master, origin/HEAD) '' (2 minutes ago) <r-lyeh>
* 5c978e9 - Initial commit (4 minutes ago) <r-lyeh>
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Unicode table - List of most common Unicode characters * | |
* This summary list contains about 2000 characters for most common ocidental/latin languages and most printable symbols but not chinese, japanese, arab, archaic and some unprintable. | |
Contains character codes in HEX (hexadecimal), decimal number, name/description and corresponding printable symbol. | |
What is Unicode? | |
Unicode is a standard created to define letters of all languages and characters such as punctuation and technical symbols. Today, UNICODE (UTF-8) is the most used character set encoding (used by almost 70% of websites, in 2013). The second most used character set is ISO-8859-1 (about 20% of websites), but this old encoding format is being replaced by Unicode. | |
How to identify the Unicode number for a character? | |
Type or paste a character: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// XLSX exporter v1.01. (tags: xlsx, ini, c++11, i18n, L10n) | |
// - rlyeh, public domain | |
// This tool exports given xlsx: | |
// | |
// ._______._____ | |
// |sheet1 \ ... \ | |
// |--------------------------------------------------- | |
// 1| LABEL | NOTES | ENGLISH | SPANISH | ... | |
// |----------+----------+-----------+-----------+----- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// from PolyGlot master sheet 0.9 - CC1.0 licensed | |
// https://github.com/PolyglotGamedev/mastersheet/blob/master/PolyglotGamedev-Master.csv | |
enum { | |
comment, | |
enUS/*enGB*/,frFR, | |
esES/*esAR esMX*/, | |
deDE/*deCH deAT*/, | |
itIT/*itCH*/, | |
ptBR,ptPT,ruRU,elGR,trTR,daDK,noNB,svSE,nlNL,plPL,fiFI,jaJP,zhCN/* zhSG*/,zhTW/* zhHK zhMO*/,koKR,csCZ,huHU,roRO,thTH,bgBG,heIL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Mike F */ | |
#include <stdint.h> | |
void *memalign( int align, size_t size ) { | |
void *mem = malloc( size + (align-1) + sizeof(void*) ); | |
if(!mem) return 0; | |
char *amem = ((char*)mem) + sizeof(void*); | |
amem += (align - ((uintptr_t)amem & (align - 1)) & (align-1)); | |
((void**)amem)[-1] = mem; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Testing read file speed for the three read functions from | |
http://cpp.indi.frih.net/blog/2014/09/how-to-read-an-entire-file-into-memory-in-cpp/ | |
compile with -std=c++11 | |
*/ | |
#include <type_traits> | |
#include <ostream> | |
#include <sstream> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// [src] https://github.com/apfeltee/cpp11-sprintf | |
#include <iostream> | |
#include <sstream> | |
#include <string> | |
std::string fmt( const char *format ) { | |
return format ? format : ""; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <string> | |
#include <iostream> | |
#include <utility> | |
void internal_func(const std::string& s) | |
{ | |
std::cout << s << '\n'; | |
} | |
template <typename ... T> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// another small variant class | |
// - rlyeh, public domain | |
#pragma once | |
#include <string> | |
#include <sstream> | |
template< typename T > | |
inline T as( const std::string &self ) { | |
T t; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <math.h> | |
int main( int argc, const char **argv ) { | |
if( argc >= 3 ) { | |
float cycle = atof(argv[1]); | |
float distance = atof(argv[2]); | |
float excess = fmodf( distance, cycle ); |
NewerOlder