Skip to content

Instantly share code, notes, and snippets.

View humbertodias's full-sized avatar

Humberto Dias humbertodias

View GitHub Profile
@jcubic
jcubic / init.java
Last active December 30, 2019 15:42
Reflection based JSON-RPC Servlet
import java.io.*;
import java.util.*;
import javax.servlet.*;
import javax.servlet.http.*;
import java.lang.reflect.*;
import com.thetransactioncompany.jsonrpc2.*;
public class init extends HttpServlet {
public init() {
@pflannery
pflannery / setup-c#7-with-unity2018-2.md
Last active January 26, 2020 00:02
Setup C# 7.x compilation in Unity 2018.2 and Visual Studio 2017

Set the unity scripting runtime to ".NET 4.x Equivalent"

In Unity goto "Edit->Preferences->Player" then find and set "Scripting Runtime Version*" to ".NET 4.x Equivalent"

Install Unity's IncrementalCompiler

In Unity:

  • Goto "Window->Package manager->All" then find and install the IncrementalCompiler
  • Goto "Unity Preferences->Compiler" and set "Enable building from IDE" to True
@andykorth
andykorth / gist:5100871
Created March 6, 2013 16:53
GLFW for C#
using System;
using System.Runtime.InteropServices;
public class GLFW {
// TODO: Obviously don't do this.
public const string GLFW_LIB = "/Users/kortham/lib/libglfw.dylib";
public static int WINDOW = 0x00010001;
@ProGM
ProGM / find_useless_resources_unity.sh
Last active January 8, 2022 10:04
A useful script to identify Unity resource that are not referenced in the project
#!/bin/bash
GREEN='\033[0;32m'
RED='\033[0;31m'
YELLOW='\033[0;33m'
NC='\033[0m'
rm unused_files.log &> /dev/null
grep -r . --include=\*.meta --exclude=*{Editor,Gizmos}* -e 'guid' | while read line; do
@BertrandBordage
BertrandBordage / cat.asm
Created April 16, 2014 19:04
Command-line read file in X86_64 intel assembly for Linux
; À compiler avec nasm -felf64 cat.asm && ld cat.o -o cat
%define SYS_EXIT 60
%define SYS_READ 0
%define SYS_WRITE 1
%define SYS_OPEN 2
%define SYS_CLOSE 3
%define STDOUT 1
%define BUFFER_SIZE 2048
@meng-hui
meng-hui / PerformBuild.cs
Last active April 20, 2022 07:44
Automated Unity Build from git repository to apk, xcode projects for use in conjunction with Jenkins. Contains Unity Editor script to collect the scenes, set the build settings, set the build location and an ant script to build the Unity project on the command line.
using UnityEditor;
using System.IO;
using System.Collections;
using UnityEngine;
using System.Collections.Generic;
class PerformBuild
{
private static string BUILD_LOCATION = "+buildlocation";
@singe
singe / request-proxy-facebook.py
Last active October 1, 2022 23:30
Simple Python requests to browser reverse proxy example.
#!/usr/bin/env python3
# A simple demo of Python requests to reverse proxy
# It's an intermediate between vanilla requests and Selenium
# It let's you interact programatically, but still run JS in
# the browser, without Selenium overhead
#
# This is an example of automating aspects of Facebook
#
# by @singe
@Aaronmacaron
Aaronmacaron / install-alacritty-ubuntu.sh
Last active October 10, 2022 11:26
Install Alacritty on Ubuntu
#!/bin/bash
# This installs alacritty terminal on ubuntu (https://github.com/jwilm/alacritty)
# You have to have rust/cargo installed for this to work
# Install required tools
sudo apt-get install -y cmake libfreetype6-dev libfontconfig1-dev xclip
# Download, compile and install Alacritty
git clone https://github.com/jwilm/alacritty
@guifromrio
guifromrio / teamcity-agent-ubuntu.md
Last active October 21, 2022 12:35
Instructions to Setup Teamcity Agent on EC2 Ubuntu 12.04.2 Linux with NodeJS and PhantomJS
@mshkrebtan
mshkrebtan / webex-ubuntu.md
Last active October 28, 2022 15:23
Run Cisco Webex on 64-bit Ubuntu 16.04

Run Cisco Webex on 64-bit Ubuntu 16.04

With Audio and Screen Sharing Enabled

Enable support for 32-bit executables

Add the i386 architecture to the list of dpkg architectures :

sudo dpkg --add-architecture i386