Skip to content

Instantly share code, notes, and snippets.

View icetee's full-sized avatar
:atom:
Development

Tamás András Horváth icetee

:atom:
Development
View GitHub Profile
@icetee
icetee / do_cp.js
Created March 23, 2017 19:06
Digitalocean VNC remote console copy paste in Developer tool
/* https://www.digitalocean.com/community/questions/copy-and-paste-into-console */
var sendString = (function(rfb, force, sendDelay) {
sendDelay = sendDelay || 25;
var _q = [];
var _qStart = function() {
var chr = _q.shift();
if (chr) {
rfb.sendKey(chr);
setTimeout(_qStart, sendDelay);
}
@icetee
icetee / grayscale.css
Created March 23, 2017 15:06
CSS3 animated grayscale
@keyframes grayscale {
0% {
filter: url("data:image/svg+xml;utf8,<svg xmlns=\'http://www.w3.org/2000/svg\'><filter id=\'grayscale\'><feColorMatrix type=\'matrix\' values=\'0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0 0 0 1 0\'/></filter></svg>#grayscale"); /* Firefox 10+, Firefox on Android */
filter: gray; /* IE6-9 */
-webkit-filter: grayscale(100%); /* Chrome 19+, Safari 6+, Safari 6+ iOS */
}
100% {
filter: url("data:image/svg+xml;utf8,<svg xmlns=\'http://www.w3.org/2000/svg\'><filter id=\'grayscale\'><feColorMatrix type=\'matrix\' values=\'1 0 0 0 0, 0 1 0 0 0, 0 0 1 0 0, 0 0 0 1 0\'/></filter></svg>#grayscale");
-webkit-filter: grayscale(0%);
}
@icetee
icetee / Custom_HTML_Signature_in_Apple_Mail_app.md
Created February 16, 2017 16:13 — forked from yugoslavskiy/Custom_HTML_Signature_in_Apple_Mail_app.md
Custom Apple Mail HTML signature creation guide
@icetee
icetee / do_ip.sh
Last active February 23, 2017 01:13
DigitalOcean refresh domain data
#!/bin/bash
# Simple IP address update with DigitalOcean API
# https://gist.github.com/icetee/85739d374380d15ebfec271f41e8bfbe
#
# Run every 15 minutes? Use `crontab -e` and paste this
# */15 * * * * /home/pi/ip.sh >/dev/null 2>&1
# -----------------------------------------------------------------------------
# Variables
API="https://api.digitalocean.com/v2"
@icetee
icetee / ls_la.ps1
Created January 6, 2017 15:34
PowerShell recurse full path list
Get-ChildItem . -recurse | % {
Write-Host $_.FullName
}
@icetee
icetee / rPi3-ap-setup.sh
Last active February 6, 2017 22:07 — forked from Lewiscowles1986/rPi3-ap-setup.sh
Raspberry Pi 3 access-point-setup
#!/bin/bash
#
# This version uses September 2016 rpi jessie image, please use this image
#
if [ "$EUID" -ne 0 ]
then echo "Must be root"
exit
fi
@icetee
icetee / IEEE2006_Szakdolgozat.xsl
Created December 16, 2016 01:12
Irodalomjegyzés stílus - szakdolgozathoz (Word >=2007) [%APPDATA%\Microsoft\Bibliography\Style]
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt"
xmlns:b="http://schemas.openxmlformats.org/officeDocument/2006/bibliography" xmlns:t="http://www.microsoft.com/temp">
<xsl:output method="html" encoding="us-ascii"/>
<xsl:template match="/">
<xsl:call-template name="Start"/>
</xsl:template>
@icetee
icetee / beep_disable.ps1
Created November 26, 2016 11:31
Disable PowerShell beep on backspace
Set-PSReadlineOption -BellStyle None
@icetee
icetee / _sortRecursive.js
Created November 25, 2016 15:48
Underscore extend recursive sort (Thanks: Craig Shoemaker)
_.sortRecursive = function(array, propName, propChild) {
array.forEach(function(item) {
var keys = _.keys(item);
keys.forEach(function(key) {
if (_.isArray(item[key])) {
item[key] = _.sortRecursive(item[key], propName);
} else if (_.isObject(item[key])) {
if (item[key].hasOwnProperty(propChild)) {
item[key][propChild] = _.sortRecursive(item[key][propChild], propName, propChild);
@icetee
icetee / localScroll.js
Last active December 13, 2016 11:31
jQuery local link scroll animation
$(document).on('click', 'a[href^="#"], a[data-scroll^="#"]', function(e) {
var id = $(this).attr('href');
if (/^#/.test(id)) {
var $id = $(id);
if ($id.length === 0) {
return;
}
} else {
id = "#" + id.split("#")[1];