Skip to content

Instantly share code, notes, and snippets.

@jaonoctus
jaonoctus / SHA256SUM
Last active April 18, 2024 14:40
Umbrel 09/15/2023
e1da1d315a7e142661b541a681c4914fcbe9f0d797de7fe863b93c2bc49318f2 install_umbrel.sh
@BaiduDownloader
BaiduDownloader / How to download from Pan.Baidu.com without account.md
Last active April 18, 2024 14:40
How to download from Pan.Baidu.com without account

How to download from Pan.Baidu.com without an account|New method 2022-2023

Untitled-1-Recovered323.png

BaiduDownloader.com. This web tool allows you to download any file or folder from Pan Baidu to any device. All you need to do is enter your Baidu link and your email address and wait a few minutes for it to download for you. Use the code “FREEDOWNLOAD1GB”. You can download any file or folder up to 1GB for free.

Baidu Cloud comes from Baidu China and is currently not open to the public. You should transfer the project folder or download the file to another cloud to use it.

Steps

1. Open the website mentioned above and select item , or uses this direct link:

https://baidudownloader.com/product/transfer-pan-baidu-com-link-to-googgle-drive-link/

@cipharius
cipharius / sort-selections.kak
Last active April 18, 2024 14:39
Sort kakoune selections using GNU sort utility
define-command sort-selections -params 0.. -override -docstring '
sort-selections: Sort current selections using GNU sort utility
All parameters will be passed to the GNU sort utility
' %{
# Copy current selections to a temporary sort buffer
execute-keys %{"sy}
edit -scratch *sort-selections*
execute-keys %{"s<a-p>}
# Seperate selections with null characters
@gmk57
gmk57 / CoroutineTimer.kt
Last active April 18, 2024 14:38
Coroutine-based solution for delayed and periodic work
/**
* Coroutine-based solution for delayed and periodic work. May fire once (if [interval] omitted)
* or periodically ([startDelay] defaults to [interval] in this case), replacing both
* `Observable.timer()` & `Observable.interval()` from RxJava.
*
* In contrast to RxJava, intervals are calculated since previous run completion; this is more
* convenient for potentially long work (prevents overlapping) and does not suffer from queueing
* multiple invocations in Doze mode on Android.
*
* Dispatcher is inherited from scope, may be overridden via [context] parameter.
@Cortexelus
Cortexelus / udio.py
Last active April 18, 2024 14:36
Automate Udio (2024-04-13)
# AUTOMATE UDIO
# by DADABOTS dadabots.com
# was working on 2024-04-13
# tldr; get your login cookie, use it to automate udio from python
import requests
import json
from time import sleep
import re
@r3dm1ke
r3dm1ke / control-flow.dart
Created November 25, 2019 20:29
Control flow statements in Dart
import 'dart:io';
void main() {
// Read some text from console
var password = stdin.readLineSync();
// Check if password is correct
if (password == 'abc') {
print('Access granted');
} else if (password == 'xyz') {
@paulirish
paulirish / gist:5558557
Last active April 18, 2024 14:32
a brief history of detecting local storage

A timeline of the last four years of detecting good old window.localStorage.


Jan Lenhart, bless his heart contributed the first patch for support:

October 2009: 5059daa

@drewchapin
drewchapin / Template.nsi
Created February 20, 2018 19:09
Template for modern NSIS installation script
;-------------------------------------------------------------------------------
; Includes
!include "MUI2.nsh"
!include "LogicLib.nsh"
!include "WinVer.nsh"
!include "x64.nsh"
;-------------------------------------------------------------------------------
; Constants
!define PRODUCT_NAME "My Application"
@P7h
P7h / tmux_vs_screen.md
Last active April 18, 2024 14:31
tmux vs screen commands

tmux vs. screen commands


Action tmux screen
start a new session tmux
tmux new
tmux new-session
screen
start a new session with a name tmux new -s name screen -S name
re-attach a detached session tmux attach
tmux attach-session
screen -r
re-attach a detached session with a name tmux attach -t name
tmux a -t name
screen -r name
re-attach an attached session (detaching it from elsewhere) tmux attach -dtmux attach-session -d screen -dr
@wojteklu
wojteklu / clean_code.md
Last active April 18, 2024 14:30
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules