Skip to content

Instantly share code, notes, and snippets.

View tgirotto's full-sized avatar

Tommaso Girotto tgirotto

View GitHub Profile
@vinodpandey
vinodpandey / MySql-5.6-installation guide.md
Last active October 4, 2024 07:39
Install MySQL 5.6.xx on Ubuntu 18.04 & Ubuntu 20.04

MySQL Download URL

https://dev.mysql.com/get/Downloads/MySQL-5.6/mysql-5.6.46-linux-glibc2.12-x86_64.tar.gz

Open the terminal and follow along:

  • Uninstall any existing version of MySQL
sudo rm /var/lib/mysql/ -R
I was drawn to programming, science, technology and science fiction
ever since I was a little kid. I can't say it's because I wanted to
make the world a better place. Not really. I was simply drawn to it
because I was drawn to it. Writing programs was fun. Figuring out how
nature works was fascinating. Science fiction felt like a grand
adventure.
Then I started a software company and poured every ounce of energy
into it. It failed. That hurt, but that part is ok. I made a lot of
mistakes and learned from them. This experience made me much, much
@putraxor
putraxor / infinite_scroll.dart
Created March 22, 2018 14:27
Flutter infinite scrolling
import 'dart:async';
import 'package:flutter/material.dart';
class InfiniteScroll extends StatefulWidget {
@override
_InfiniteScrollState createState() => new _InfiniteScrollState();
}
class _InfiniteScrollState extends State<InfiniteScroll> {
@jynik
jynik / ready_set_yocto.txt
Last active May 16, 2024 06:30
Ready, Set, Yocto! (v0.3) : A short guide to getting started with Yocto
================================================================================
Ready, Set, Yocto! (v0.3)
A short guide to getting started with Yocto
using YP Rocko 2.4 the Raspberry Pi
jynik
================================================================================
-------------------------------------------------
1. Intro
@oinopion
oinopion / read-access.sql
Created October 5, 2016 13:00
How to create read only user in PostgreSQL
-- Create a group
CREATE ROLE readaccess;
-- Grant access to existing tables
GRANT USAGE ON SCHEMA public TO readaccess;
GRANT SELECT ON ALL TABLES IN SCHEMA public TO readaccess;
-- Grant access to future tables
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO readaccess;
@ygotthilf
ygotthilf / jwtRS256.sh
Last active November 7, 2024 10:42
How to generate JWT RS256 key
ssh-keygen -t rsa -b 4096 -m PEM -f jwtRS256.key
# Don't add passphrase
openssl rsa -in jwtRS256.key -pubout -outform PEM -out jwtRS256.key.pub
cat jwtRS256.key
cat jwtRS256.key.pub
public void elementClicked(int position){
if (view != null){
final int word = view.getWordByPosition(int position)
view.doAnimationStuff();
view.launchActivityWithWord(word);
}
}
//because there are no android dependencies here, it becomes easy to implement Mockito style behavioral testing.
@arisetyo
arisetyo / index.html
Created July 12, 2013 16:37
Dynamic Real-time Chart Using Chart.js, Socket.io, and Knockout.js
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="author" content="Galenic">
<script src="js/jquery-1.9.1.js"></script>
<script src="js/knockout-2.1.0.js"></script>
<script src="js/Chart.js"></script>
<link rel="stylesheet" href="pure-min.css">

tmux cheatsheet

As configured in my dotfiles.

start new:

tmux

start new with session name: