Skip to content

Instantly share code, notes, and snippets.

View spac3unit's full-sized avatar

Denis spac3unit

View GitHub Profile
@spac3unit
spac3unit / tailwind_md_all_colours.js
Created May 29, 2024 13:07 — forked from davidpiesse/tailwind_md_all_colours.js
A colour set for Tailwind CSS that include all Material Design Colours, shades, accents and contrast colours
// https://davidpiesse.github.io/tailwind-md-colours/
//
//Notes
//
//All colours are generated from Material Design Docs
//Colours have a base, a set of shades (50-900) accent colours
//In addition a companion set of contrast colours are included for colouring text / icons
// Example usage
// class="w-full bg-red-600 text-red-600-constrast"
@spac3unit
spac3unit / init.lua
Created September 18, 2023 18:49 — forked from mekeor/init.lua
A Minimal Neovim Configuration for TypeScript Development featuring Lazy.nvim, LSP, Tree-Sitter, Prettier, Guess-Indent
---- about this neovim-configuration
-- - features: completion, lsp, tree-sitter, formatter, automatic configuration of indendation.
-- - goals: web development with typescript and tsx.
-- - themes: on mac, one-light; otherwise, gruvbox.
---- external setup
-- - install git and neovim. e.g., with guix as package-manager, run:
-- guix install git neovim
@spac3unit
spac3unit / clean-up-arch-linux.md
Created September 16, 2023 20:46 — forked from rumansaleem/clean-up-arch-linux.md
Instructions to clean up Arch Linux (Manjaro)

Contents

  • Clean pkg cache
  • Remove unused packages (orphans)
  • Clean cache in /home
  • remove old config files
  • Find and Remove
    • duplicates
    • empty files
    • empty directories
  • broken symlinks
@spac3unit
spac3unit / screenshot.py
Created October 31, 2022 15:28 — forked from initbrain/screenshot.py
Python screenshot tool (fullscreen/area selection)
#!/usr/bin/env python
# Python screenshot tool (fullscreen/area selection)
# Tested on:
# Lubuntu 13.04 x86_64
# Gentoo 4.1.7-hardened-r1 x86_64
import sys
from PyQt4 import QtCore, QtGui
from commands import getoutput
from StringIO import StringIO
"editor.tokenColorCustomizations": {
"textMateRules": [
{
"scope": [
"comment",
"comment.block",
"comment.block.documentation",
"comment.line",
"constant",
"constant.character",
🌞 Morning 28 commits ██░░░░░░░░░░░░░░░░░░░ 9.9%
🌆 Daytime 94 commits ██████▉░░░░░░░░░░░░░░ 33.3%
🌃 Evening 113 commits ████████▍░░░░░░░░░░░░ 40.1%
🌙 Night 47 commits ███▍░░░░░░░░░░░░░░░░░ 16.7%
@spac3unit
spac3unit / unfollow-non-followers-twitter.js
Created November 11, 2021 20:02 — forked from YogaSakti/unfollow-non-followers-twitter.js
Code to stop following those ones who are not following you back on Twitter and keeping those you want or follow anyone you want, with certain filters (working in July 2019)
/*
Unfollow (stop following) those people who are not following you back on Twitter (or unfollow everyone if desired).
This will work for new Twitter web site code structure (it was changed from July 2019, causing other unfollow-scripts to stop working).
Instructions:
1) The code may need to be modified depending on the language of your Twitter web site:
* For English language web site, no modification needed.
* For Spanish language web site, remember to set the 'LANGUAGE' variable to "ES".
* For another language, remember to set the 'LANGUAGE' variable to that language and modify the 'WORDS' object to add the words in that language.
@spac3unit
spac3unit / massa.sh
Created November 11, 2021 20:01 — forked from YogaSakti/massa.sh
massa auto buy roll
#!/bin/bash
DELAY=300 #in secs - how often restart the script
ROLL_PRICE=100
for (( ;; )); do
WALLET=$(massa-client wallet_info)
ADDRESS=$(echo -e $WALLET | grep -oP 'Address:\s*\K.*(?=\s+State)')
FINAL_BAL=$(echo -e $WALLET | grep -oP 'final balance:\s*\K.*(?=\s+candidate balance)')
@spac3unit
spac3unit / tokens.md
Created October 21, 2021 20:36 — forked from zmts/tokens.md
Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Last major update: 25.08.2020

  • Что такое авторизация/аутентификация
  • Где хранить токены
  • Как ставить куки ?
  • Процесс логина
  • Процесс рефреш токенов
  • Кража токенов/Механизм контроля токенов
@spac3unit
spac3unit / telegramChannelBot.md
Created October 21, 2021 20:34 — forked from zmts/telegramChannelBot.md
Используем Telegram канал в качестве системы оповещения

Используем Telegram канал в качестве системы оповещения

  • Создаем бота через глобального бота телеграма @BotFather
  • Создаем публичный канал через обычный клиент(desktop/mobile) с публичным именем
  • Добавляем бота в администраторы канала (с правами отправлять сообщения)
  • Отправляем тестовое сообщение в канал от имени только что созданного бота
#POST: https://api.telegram.org/bot<token>/sendMessage
{
  "chat_id": "@mysuperchannel",