Skip to content

Instantly share code, notes, and snippets.

View estevanjantsk's full-sized avatar
:shipit:

Estevan Jantsk estevanjantsk

:shipit:
View GitHub Profile
@estevanjantsk
estevanjantsk / jsonnet.txt
Created November 26, 2015 14:40
JSONNETExample e JavaScriptSerializerExample
using Newtonsoft.Json;
// deserialize JSON directly from a file
String JSONstring = File.ReadAllText("JSON.json");
Person p1 = JsonConvert.DeserializeObject<Person>(JSONstring);
Console.WriteLine(p1);
// output JSON file
$stateProvider
.state('angular',
url: '/'
controller: 'GeneralController'
views:
'sidebar':
templateUrl: 'sidebar.html'
controller: 'SidebarController'
'header':
templateUrl: 'header/header.html'
@estevanjantsk
estevanjantsk / 0_reuse_code.js
Created December 19, 2016 12:11
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@estevanjantsk
estevanjantsk / new_rails_app_cheatsheet.txt
Last active February 1, 2017 01:25 — forked from fajrif/rvm_cheatsheet
RVM cheatsheet
1. Open terminal and check versions of Ruby on Rails agains production server params or to make sure you are using the mos recent stable version.
$ ruby -v
$ rvm list
$ rvm list know
$ rvm install ruby 2.2.1
$ rvm list
$ ruby -v
$ gem install rails
$ rails -v
@estevanjantsk
estevanjantsk / README.md
Created October 28, 2017 19:20 — forked from denji/README.md
Remove/Backup – settings & cli for macOS (OS X) – DataGrip, AppCode, CLion, Gogland, IntelliJ, PhpStorm, PyCharm, Rider, RubyMine, WebStorm
# remove specific file from git cache
git rm --cached filename
# remove all files from git cache
git rm -r --cached .
git add .
git commit -m ".gitignore is now working"
@estevanjantsk
estevanjantsk / Update .gitignore
Created March 5, 2018 00:21 — forked from c33k/Update .gitignore
Updating .gitignore and cleaning the cache
//First commit any outstanding code changes, and then, run this command:
git rm -r --cached .
//This removes any changed files from the index(staging area), then just run:
git add .
//Commit
git commit -m "Atualizando .gitignore para..."
@estevanjantsk
estevanjantsk / upgrade.sh
Created March 13, 2018 12:19 — forked from bocharsky-bw/upgrade.sh
Shell Script for Upgrade Ubuntu via APT in one step
#!/bin/bash
TEXT_RESET='\e[0m'
TEXT_YELLOW='\e[0;33m'
TEXT_RED_B='\e[1;31m'
sudo apt-get update
echo -e $TEXT_YELLOW
echo 'APT update finished...'
echo -e $TEXT_RESET
@estevanjantsk
estevanjantsk / client.js
Created November 21, 2018 00:54 — forked from crtr0/client.js
A simple example of setting-up dynamic "rooms" for socket.io clients to join
// set-up a connection between the client and the server
var socket = io.connect();
// let's assume that the client page, once rendered, knows what room it wants to join
var room = "abc123";
socket.on('connect', function() {
// Connected, let's sign-up for to receive messages for this room
socket.emit('room', room);
});
@estevanjantsk
estevanjantsk / StreamMixer.ts
Created December 13, 2018 23:38 — forked from grishgrigoryan/StreamMixer.ts
StreamMixer helps to play with MediaStream: Merge multiple streams into single one ( can be used with WebRtc to send multiple streams over a single WebRTC MediaConnection, or to switch streams without worrying about renegotiation)
export class StreamMixer {
streams: Array<{
id: string,
audioSource: any,
gainNode: any,
mediaStream: MediaStream
}>;
destination: any;
audioCtx: any;