Skip to content

Instantly share code, notes, and snippets.

View lucasteles's full-sized avatar
:shipit:
Ship it!

Lucas Teles lucasteles

:shipit:
Ship it!
View GitHub Profile
public class DataTableParameters
{
public List<DataTableColumn> Columns { get; set; }
public int Draw { get; set; }
public int Length { get; set; }
public List<DataOrder> Order { get; set; }
public Search Search { get; set; }
public int Start { get; set; }
@huytd
huytd / .gitconfig
Created August 4, 2016 16:26
Use neovim as diff tool
[merge]
tool = vimdiff
[mergetool]
prompt = true
[mergetool "vimdiff"]
cmd = nvim -d $LOCAL $REMOTE $MERGED -c '$wincmd w' -c 'wincmd J'
[difftool]
prompt = false
[diff]
tool = vimdiff
@Mistobaan
Mistobaan / build_vim.sh
Last active July 18, 2019 18:22
Compile VIM from branch on UBUNTU 16.04
#!/bin/sh
set -e
sudo apt-get remove --purge vim vim-runtime vim-gnome vim-tiny vim-common vim-gui-common
sudo apt-get install liblua5.1-dev luajit libluajit-5.1 python-dev ruby-dev libperl-dev mercurial libncurses5-dev libgnome2-dev libgnomeui-dev libgtk2.0-dev libatk1.0-dev libbonoboui2-dev libcairo2-dev libx11-dev
sudo mkdir -p /usr/include/lua5.1/include
sudo ln -s /usr/include/luajit-2.0 /usr/include/lua5.1/include
@lucascebertin
lucascebertin / quake.fsx
Last active March 23, 2017 00:38
F# - Quake log parser
open System
open System.Data
open System.IO
open System.Text.RegularExpressions
type DeathTypes =
| MOD_UNKNOWN=1 | MOD_SHOTGUN=2 | MOD_GAUNTLET=3 | MOD_MACHINEGUN=4
| MOD_GRENADE_SPLASH=5 | MOD_ROCKET=6 | MOD_ROCKET_SPLASH=7 | MOD_PLASMA=8
| MOD_PLASMA_SPLASH=9 | MOD_RAILGUN=10 | MOD_LIGHTNING=11 | MOD_BFG=12
| MOD_BFG_SPLASH=13 | MOD_WATER=14 | MOD_SLIME=15 | MOD_LAVA=16
@Azoy
Azoy / install-swift-ubuntu.md
Last active December 9, 2022 03:42
Guide on how to install Swift on Ubuntu

Install Swift on Ubuntu

Requirements

  1. Ubuntu 14.04, 16.04, or 16.10

Step 1 - Dependencies

  1. Open up terminal
  2. Install core deps: sudo apt-get install clang libicu-dev git

Step 1.1 - Ubuntu 14.04 Clang

@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active June 8, 2024 13:20
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

@AlbertoMonteiro
AlbertoMonteiro / ObjectSpread.cs
Created February 14, 2018 23:24
Spread object in C#
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Reflection.Emit;
namespace Playground
{
public class Program
using System.Runtime.CompilerServices;
using BenchmarkDotNet.Attributes;
using BenchmarkDotNet.Running;
public struct Matrix4x4
{
public float M11, M12, M13, M14;
public float M21, M22, M23, M24;
public float M31, M32, M33, M34;
public float M41, M42, M43, M44;
@ndc
ndc / HFDashboardAuthFilter.cs
Created September 1, 2018 12:30
Hangfire dashboard authorization filter using basic authentication and relying on browser support to allow user to input username and password.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Hangfire.Annotations;
using Hangfire.Dashboard;
using Microsoft.AspNetCore.Http;
namespace MyApp.ScheduledTask
{
@krisleech
krisleech / renew-gpgkey.md
Last active June 5, 2024 14:43
Renew Expired GPG key

Renew GPG key

Given that your key has expired.

$ gpg --list-keys
$ gpg --edit-key KEYID

Use the expire command to set a new expire date: