Skip to content

Instantly share code, notes, and snippets.

View djumaka's full-sized avatar

Boyan Djumakov djumaka

  • Sofia, Bulgaria
View GitHub Profile

Keybase proof

I hereby claim:

  • I am djumaka on github.
  • I am djumaka (https://keybase.io/djumaka) on keybase.
  • I have a public key ASCD7HiO_h7wPXZhYOzPCqneJXI1Jxp_AqQh_ShBax5k0wo

To claim this, I am signing this object:

@djumaka
djumaka / hariot-sonoff.ino
Created August 22, 2017 06:02
basic sonoff node ino file
/*
1MB flash sizee
sonoff header
1 - vcc 3v3
2 - rx
3 - tx
4 - gnd
@djumaka
djumaka / js_decoder
Created May 18, 2016 12:48
decode encrypted JS file from array to real code
<?php
$jsString = file_get_contents("./load_save_banner.js");
preg_match("/^var (.*?) = (\[.*?\]);/i", $jsString, $output_array);
$varName = $output_array[1];
$varData = eval('return '.$output_array[2].';');
foreach($varData as $key => $val) {
$jsString = str_replace($varName.'['.$key.']', "\"".addslashes($val)."\"", $jsString);
}
@djumaka
djumaka / jira_logtime_notifier
Created March 18, 2016 13:23
An small script to send out emails at the end of the day, for users that didn't log their working time in jira.
<?php
require "PHPMailer/PHPMailerAutoload.php";
date_default_timezone_set('UTC');
$server = 'your-jira.atlassian.net';
$jiraname = 'jira.api.username';
$jiraPassword = 'jira.api.username';
$reportDate = date("Y/m/d");
$assignees = array(
'jira.username' => array(
@djumaka
djumaka / .htaccess
Last active December 9, 2015 15:21
A working HTACCESS rule file for Angular.JS HTML5 mode
<ifModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/(img|js|app|css|robots\.txt|favicon\.ico)(.*)$ [NC]
RewriteRule ^ index.php [NC,L]
</ifModule>
int ledPin = 13;
String cmd = "";
String tmpCmd = "";
boolean readCmd = false;
void setup () {
Serial.begin (9600);
pinMode(ledPin, OUTPUT);
}
void loop () {