Skip to content

Instantly share code, notes, and snippets.

View raveren's full-sized avatar

Rokas Šleinius raveren

View GitHub Profile
@raveren
raveren / bitbucket-improvements-ecu.user.js
Last active February 21, 2024 07:01
ECU Bitbucket Improvements
// ==UserScript==
// @name ECU Bitbucket Improvements
// @namespace https://greasyfork.org/en/scripts/458896
// @homepageURL https://gist.github.com/raveren/3bd55656272143f667e9cfd7e7171c52
// @license MIT
// @version 1.3.0
// @author raveren
// @description Changes page titles to be informative, makes branch name click to copy, and links PHPStorm from diff line
// @require https://code.jquery.com/jquery-3.7.1.min.js
// @match https://bitbucket.org/ecu1/internal-www/pull-requests*
function change_colors () {
h += 1
if (h > 360) {
h = 0
}
strip.showColor(neopixel.hsl(h, l, s))
strip2.showColor(neopixel.hsl(360 - h, l, s))
basic.pause(10)
}
function flags () {
@raveren
raveren / justo-aliarmas.ino
Last active May 12, 2022 17:45
arduino alarm clock consisting of RTC_DS3231 clock module, button and old school phone dial. https://photos.app.goo.gl/sZ6CsrMxHYXJodcP6
/*
rodo laika
pradejus rinkti - nustatomas zadintuvas
paspaudus sverti - rodo zadintuvo laika (arba 8888 jei dar neivestas)
palaikius sverti 5 sek - nustatomas laikas
skamba zadintuvas
skamba minute - tada snuzina 5 min
paspaudus sverti - uzsnuzina 5 min
@raveren
raveren / init.lua
Created June 8, 2021 14:19
Hammerspoon personal config
-- Define some keyboard modifier variables
-- (Node: Capslock bound to cmd+alt+ctrl+shift via Seil and Karabiner)
local hyper = {"⌘", "⌥", "⌃", "⇧"}
-- Reload config
function reloadConfig(paths)
doReload = false
for _,file in pairs(paths) do
if file:sub(-4) == ".lua" then
print("A lua file changed, doing reload")
<?php

namespace App\Http\Controllers;

class MyController extends Controller
{
    public function update(BBJUpdateRequest $request, MyService $myService)
 {
@raveren
raveren / kint.php
Last active October 2, 2021 14:36
Config file for Kint (php debug helper). More info: https://kint-php.github.io/kint/settings/
<?php
/* ####################################################################
* Original, changes welcome:
*
* https://gist.github.com/raveren/eba373d8abb572b0528c73d145103f95
*
* More info:
*
* https://kint-php.github.io/kint/settings/
<?php
\Symfony\Component\VarDumper\Dumper\CliDumper::$defaultOutput = 'php://output';
\Symfony\Component\VarDumper\VarDumper::setHandler(function ($var) {
$cloner = new \Symfony\Component\VarDumper\Cloner\VarCloner();
$dumper = new \Symfony\Component\VarDumper\Dumper\CliDumper();
$dumper->dump($cloner->cloneVar($var));
});
@raveren
raveren / show-all-aliexpress-orders.user.js
Last active October 1, 2020 12:42
Show all your orders on one page in Aliexpress
// ==UserScript==
// @name Aliexpress show all orders
// @namespace none
// @version 0.1
// @date 2019-12-11
// @description Add new option to the 'Display items per page:' dropdown
// @author raveren
// @match *.aliexpress.com/orderList.htm*
// @match *.aliexpress.com/order_list.htm*
// @icon https://ae01.alicdn.com/images/eng/wholesale/icon/aliexpress.ico
//////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////// DEFINITIONS //////////////////////////////////////////////
///////////////// YOU CAN CHANGE CODE AT THE BOTTOM ///////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////////////
const display = [
1, 1, 1, 0, 1, 1, 1,
1, 1, 1, 0, 1, 1, 1,
1, 1,
1, 1, 1, 0, 1, 1, 1,
@raveren
raveren / GitHub-add-RubyMine-link.user.js
Last active July 15, 2016 12:02
Link File to InteliJ IDE From Github