Skip to content

Instantly share code, notes, and snippets.

View 0x6d6c's full-sized avatar

Michał Lüth 0x6d6c

View GitHub Profile
<?php
declare(strict_types=1);
namespace App;
struct User {
string $identifier;
}
@tomekziel
tomekziel / struktura.json
Created January 27, 2022 20:35
Struktura sądów wg portalu informacyjnego sądów powszechnych, stan na 2022.01.27
[
{
"name": "Sąd Apelacyjny w Białymstoku",
"zrskId": 2010,
"departments": [
{
"name": "I Wydział Cywilny",
"zrskId": 50067267,
"number": "I",
"repertories": [
using System;
using System.Collections.Generic;
using System.IO;
using System.Net.Http;
using System.Net.Http.Json;
using System.Text.Encodings.Web;
using System.Text.Json;
using System.Text.Json.Serialization;
using System.Text.Unicode;
<?
//
// AUTO KEYWORD-BASED FOLLOWER CURATION BOT (by @levelsio)
//
// File: twitterFollowerCuratorBot.php
//
// Created: May 2021
// License: MIT
//
@tkadlec
tkadlec / perf-diagnostics.css
Last active June 8, 2023 17:47
CSS used to highlight potential performance issues
:root {
--violation-color: red; /* used for clear issues */
--warning-color: orange; /* used for potential issues we should look into */
}
/* IMAGES */
/*
* Lazy-Loaded Images Check
* ====
@monteiro
monteiro / HomepageController.php
Last active March 3, 2024 14:23
Redirect to page according to the Accept-Language header using Symfony 5
<?php
namespace App\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Routing\Annotation\Route;
class HomepageController extends AbstractController
{
@antoninbouchal
antoninbouchal / .gitlab-ci.yml
Last active June 30, 2024 18:48
Deploy APP through SSH to VPS with Gitlab CI
stages:
- build
- deploy
before_script:
- |
# docker variables for name and tag of new image
export DOCKER_TAG="${CI_COMMIT_SHA:0:8}"
export DOCKER_REPO="$CI_REGISTRY_IMAGE"
export DOCKER_IMAGE="${DOCKER_REPO}:${DOCKER_TAG}"
@olucheye
olucheye / frontendDevlopmentBookmarks.md
Created November 11, 2019 11:24 — forked from dypsilon/frontendDevlopmentBookmarks.md
A badass list of frontend development resources I collected over time.
@cengiz-io
cengiz-io / 99-disable-wireless-when-wired
Last active October 9, 2023 16:36
Script should be placed under `/etc/NetworkManager/dispatcher.d/` with a name like `99-disable-wireless-when-wired`. Make sure 1) root owns it 2) it's mod is 755
#!/bin/sh
IFACE=$1
ACTION=$2
ntfy () {
sudo -u cengiz \
DISPLAY=:0 \
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus \
notify-send "$1" "$2"
@rawdatalab
rawdatalab / stillalive.rc
Created April 11, 2019 17:42
STILL ALIVE as a Bash script with beep (didn't create, just sharing)
# Let 'em know that we're Still Alive
# http://pastebin.com/f72f8f72d (no longer valid)
#!/bin/bash
echo -n "This "
beep -f 784 -l 200
echo -n "was "
beep -f 740 -l 200
echo -n "a "
beep -f 659 -l 200