Skip to content

Instantly share code, notes, and snippets.

View vviikk's full-sized avatar
🙃

Vik Ramanujam vviikk

🙃
View GitHub Profile
@vviikk
vviikk / joom_dbbak.php
Created February 14, 2014 08:14
Easy way to backup Joomla database by using db login credentials from configuration.php. Original idea from http://davidwalsh.name/backup-mysql-database-php
<?php
require_once( 'configuration.php' );
$Config = new JConfig();
backup_tables($Config->host,$Config->user,$Config->password,$Config->db);
/* backup the db OR just a table */
function backup_tables($host,$user,$pass,$name,$tables = '*')
@vviikk
vviikk / proxyscript.sh
Created May 27, 2016 12:19 — forked from kamermanpr/proxyscript.sh
Bash script to toggle proxy server settings for the terminal, git, and R based on network location setting (OSX)
#!/bin/bash
# By Peter Kamerman (peter.kamerman@gmail.com)
##########
# FUNCTION
##########
# Script to toggle the proxy configurations of the terminal, git, and R
# for use behind a proxy server (e.g., at work) and no proxy (e.g., home).
########################
# DISCLAIMER and LICENSE
########################
ç
@vviikk
vviikk / cVim Settings
Last active October 5, 2016 14:31
My cVim Settings
set smoothscroll
set noautofocus " The opposite of autofocus; this setting stops
" sites from focusing on an input box when they load
let barposition = "bottom"
" This unmaps the default 'h', 'j', 'k', and 'l' mappings
unmap J K
map K previousTab " I use Vivaldi with tabs on the side
map J nextTab " so this makes more sense
@vviikk
vviikk / cloudSettings
Last active January 11, 2017 16:48
Visual Studio Code Sync Settings GIST
{"lastUpload":"2017-01-11T16:48:29.055Z"}
@vviikk
vviikk / .minttyrc
Created October 25, 2016 05:30
Powerline on Babun using bobthefish theme from Oh-my-fish on fish shell
# Using bobthefish theme from Oh-my-fish on fish shell
BoldAsFone=no
Font=Dejavu Sans Mono for Powerline
FontHeight=10
@vviikk
vviikk / userChrome.css
Last active June 2, 2018 11:28
My firefox visual hacks
/* Hide horizontal tabs at the top of the window #1349 */
#TabsToolbar {
visibility: collapse !important;
}
/* For only Tree Style Tab sidebar #1397 */
#sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"] #sidebar-header {
display: none !important;
}
@vviikk
vviikk / test-svg-with-js.svg
Created June 25, 2018 06:49
SVG with js test
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@vviikk
vviikk / event-schedule-utility-function.markdown
Created October 22, 2018 15:07
Event schedule utility function
@vviikk
vviikk / custom-property-naming-constants.css
Last active November 12, 2018 19:59
A super simple way CSS custom properties naming convention
:root {
--FONT-SIZE-MIN: 16;
--FONT-SIZE-MAX: 26;
/* The properties below are also constants, as they don't rely on any external variables and are not calculated */
--FONT-SIZE-MIN-PX: var(--FONT-SIZE-MIN) * 1px;
--FONT-SIZE-MAX-PX: var(--FONT-SIZE-MAX) * 1px;
/* Direct value assignement */
--COLOR-PRIMARY: palevioletred;