Skip to content

Instantly share code, notes, and snippets.

@renerdias
renerdias / media-query.css
Created December 9, 2018 16:38 — forked from gokulkrishh/media-query.css
CSS Media Queries for Desktop, Tablet, Mobile.
/*
##Device = Desktops
##Screen = 1281px to higher resolution desktops
*/
@media (min-width: 1281px) {
//CSS
@renerdias
renerdias / backup_pg.sh
Created April 7, 2019 15:29 — forked from sjlombardo/backup_pg.sh
PostgreSQL Daily Continuous Backup Script
#!/bin/bash
backup_dir=/backup/pg_backups
wal_dir=/backup/postgresql
today=$(date +%Y-%m-%d.%H:%M:%S)
yesterday=$(find $backup_dir -maxdepth 1 -type d -name "*" -exec basename {} \; | tail -n +2 | grep -v "lost+found" | sort -rn | head -1)
psql -c "select pg_start_backup('$today', true);"
if [ $? = 0 ]
@renerdias
renerdias / tg_auditoria.sql
Last active April 19, 2019 23:43 — forked from wyanez/tg_auditoria.sql
[pgsql] Modelo de Trigger de Auditoria en PostgreSQL
DECLARE
inst TEXT;
old_v TEXT;
new_v TEXT;
alterado_v BOOLEAN;
metadata_record RECORD;
BEGIN
RAISE NOTICE '(%) -> % [%,%,%]',TG_OP, TG_TABLE_NAME,current_user,current_time,current_date;
alterado_v = FALSE;
raise notice '1°: %', alterado_v;
@renerdias
renerdias / gist:c389f0d630bb1a73e3c5992d3aff3c6d
Created April 23, 2019 13:52 — forked from rxaviers/gist:7360908
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
-- Create a mySQL table to hold hashed passwords and random salt
--
-- SQL create script for for table `users`
--
CREATE TABLE IF NOT EXISTS `users` (
`user_id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT,
`email` varchar(30) NOT NULL,
`reg_date` date NOT NULL,
@renerdias
renerdias / default nginx configuration file
Created January 11, 2020 16:04 — forked from xameeramir/default nginx configuration file
The default nginx configuration file inside /etc/nginx/sites-available/default
##
# You should look at the following URL's in order to grasp a solid understanding
# of Nginx configuration files in order to fully unleash the power of Nginx.
# http://wiki.nginx.org/Pitfalls
# http://wiki.nginx.org/QuickStart
# http://wiki.nginx.org/Configuration
#
# Generally, you will want to move this file somewhere, and start with a clean
# file but keep this around for reference. Or just disable in sites-enabled.
#