Skip to content

Instantly share code, notes, and snippets.

View renefs's full-sized avatar
👋

René Fernández renefs

👋
View GitHub Profile
@renefs
renefs / patch-edid.rb
Last active May 24, 2019 14:20 — forked from adaugherity/patch-edid.rb
Script to improve quality settings in external screens connected to Mac
#!/usr/bin/ruby
# Create display override file to force Mac OS X to use RGB mode for Display
# see http://embdev.net/topic/284710
require 'base64'
data=`ioreg -l -d0 -w 0 -r -c AppleDisplay`
edids=data.scan(/IODisplayEDID.*?<([a-z0-9]+)>/i).flatten
vendorids=data.scan(/DisplayVendorID.*?([0-9]+)/i).flatten
@renefs
renefs / export.py
Last active April 2, 2024 17:24
Genera un CSV para exportar de FilmAffinity
#! /usr/bin/python3
# Author: Pablo Baeyens
# Usage:
# ./faScrap.py -h
# for usage info and options
import time
import argparse
import requests
import csv
import React from 'react'
import { Text, View, StatusBar } from 'react-native'
import { PropTypes } from 'prop-types'
import { createStore } from 'redux'
import { Constants } from 'expo'
import { Provider } from 'react-redux'
import { createBottomTabNavigator, createStackNavigator } from 'react-navigation'
function entries (state = {}, action) {
}
@renefs
renefs / docker_stop.txt
Last active May 11, 2018 08:26
Stop and clear all the Docker containers
docker stop $(docker ps -a -q) && docker rm $(docker ps -a -q)
#!/bin/bash
cd /home/projects/project
. ./env/bin/activate
# Extract the package
tar -xzf package.tgz
rm package.tgz
rm ./web/project/config.py
cp ./config.py ./web/project/config.py
@renefs
renefs / gitlab-ci.yml
Created November 1, 2017 15:11
Ember Continuous Integration with Gitlab CI
stages:
- prepare
- test
- build
- deploy
variables:
EMBER_CLI_VERSION: "2.16.2"
BOWER_VERSION: "1.8.2"
PHANTOMJS_VERSION: "2.1.15"
@renefs
renefs / example.js
Created June 13, 2017 08:14
Yuidoc Ember example
import Ember from 'ember';
/**
* The login controller shows the login form and sends authentication data to the session.
*
* @class login
* @namespace Controller
*/
export default Ember.Controller.extend({
@renefs
renefs / git-command.sh
Created November 7, 2015 15:49
How to rewrite git commit username and password.
git filter-branch -f --env-filter \
"GIT_AUTHOR_NAME='<NEW USERNAME>'; GIT_AUTHOR_EMAIL='<NEW EMAIL>'; \
GIT_COMMITTER_EMAIL='<Old Email>';" HEAD
@renefs
renefs / backup_cron.sh
Created May 26, 2014 10:17
Database Backup sent by email and triggered at 4AM using CRON.
DBNAME="<DB_NAME>"
DBPASS="<PASSWORD>"
DBUSER="<USER>"
EMAIL="<EMAIL>"
mysqldump --opt -u $DBUSER -p$DBPASS $DBNAME > backup.sql
gzip backup.sql
DATE=`date +%Y%m%d` ; mv backup.sql.gz $DBNAME-backupFULL-$DATE.sql.gz
uuencode $DBNAME-backupFULL-$DATE.sql.gz $DBNAME-backupFULL-$DATE.sql.gz | mail -s "<SUBJECT>" $EMAIL
rm $DBNAME-backupFULL-$DATE.sql.gz
@renefs
renefs / css_resources.md
Created April 24, 2014 22:30 — forked from jookyboi/css_resources.md
CSS libraries and guides to bring some order to the chaos.

Libraries

  • 960 Grid System - An effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. There are two variants: 12 and 16 columns, which can be used separately or in tandem.
  • Compass - Open source CSS Authoring Framework.
  • Bootstrap - Sleek, intuitive, and powerful mobile first front-end framework for faster and easier web development.
  • Font Awesome - The iconic font designed for Bootstrap.
  • Zurb Foundation - Framework for writing responsive web sites.
  • SASS - CSS extension language which allows variables, mixins and rules nesting.
  • Skeleton - Boilerplate for responsive, mobile-friendly development.

Guides