Skip to content

Instantly share code, notes, and snippets.

View hugochinchilla's full-sized avatar
🤖
I'm not a robot

Hugo Chinchilla Carbonell hugochinchilla

🤖
I'm not a robot
View GitHub Profile
@schmich
schmich / ducky.md
Last active April 5, 2024 14:20
Programming media keys on the Ducky One 2 Skyline

Programming Media Keys on the Ducky One 2 Skyline

To use media keys on the Ducky One 2 Skyline, you must record a macro to bind the media function to a hotkey combination, i.e. Fn plus some key.

Example

Important: In the instructions below, "Press X+Y+Z" means press and hold key X, press and hold key Y, press and hold key Z in that order, and then release all three.

As an example, to bind Fn+PgUp to the play/pause media function:

@checco
checco / rw_ro_access.sql
Last active March 22, 2024 08:32 — forked from oinopion/read-access.sql
How to create a read only user in AWS RDS PostgreSQL and a user with superuser privileges on AWS RDS PostgreSQL
--
-- Read only
--
-- Create a group
CREATE ROLE postgres_ro_group;
-- Grant access to existing tables
GRANT USAGE ON SCHEMA public TO postgres_ro_group;
GRANT SELECT ON ALL TABLES IN SCHEMA public TO postgres_ro_group;
@vizath
vizath / Responsive.js
Last active April 30, 2018 04:54
Create an object that you can listen on for screen sizes with incomplete Bootstrap example.
"use strict";
var EventEmitter = require('events').EventEmitter;
var CHANGE_EVENT = 'change';
var breakpoints = [0, 768, 992, 1200, Infinity];
var indexes;
var getSize = function() {
// http://stackoverflow.com/a/11744120/808657
@parties
parties / responsive-fitted-table.jsx
Last active March 13, 2020 20:02
Responsive Wrapper for Facebook's Fixed Data Table
var React = require('react');
var {Table} = require('fixed-data-table');
var _ = require('lodash');
var FittedTable = React.createClass({
getInitialState() {
return {
tableWidth : 400,
tableHeight : 400
};
window.addEventListener('storage', function(e) {
if (e.storageArea === localStorage) {
var key = e.key;
if (data) {
$(document).trigger('storage.' + e.key, data);
}
}
});
$(document).on("storage.test", function(e, data) {
@andremedeiros
andremedeiros / talks.md
Last active August 29, 2015 14:06
Baruco 2014 talks

Baruco 2014 talks

Please see the Hackpad where we can all contribute!

@jpalumickas
jpalumickas / baruco2014_presentations.md
Last active August 29, 2015 14:06
Baruco 2014 Presentations

Baruco 2014

Friday

Yukihiro Matsumoto (mruby: AltRuby)

Piotr Szotkowski (Standard Library, Uncommon Uses) http://talks.chastell.net/baruco-2014

Pat Shaughnessy (Twenty Thousand Leagues Under ActiveRecord)

@andris9
andris9 / README.md
Last active December 29, 2022 02:38
Extremely simple HTTP proxy for changing Host: header Useful when proxying requests to virtual hosts that require Host: header to be set.

Setup reverse tunnel

Run the following in your client machine

ssh -R EXPOSED_PORT:localhost:SERVICE_PORT USER@HOST

Where

  • EXPOSED_PORT is the port exposed to the internet in the proxy server
  • SERVICE_PORT is the port your application is listening in your machine
@wsargent
wsargent / docker_cheat.md
Last active August 31, 2023 12:10
Docker cheat sheet
@ChrisBeaumont
ChrisBeaumont / custom.css
Last active June 22, 2022 15:20
Demystifying Python Descriptors
<style>
@font-face {
font-family: "Computer Modern";
src: url('http://mirrors.ctan.org/fonts/cm-unicode/fonts/otf/cmunss.otf');
}
div.cell{
width:800px;
margin-left:16% !important;
margin-right:auto;
}