Skip to content

Instantly share code, notes, and snippets.

@mxalbert1996
mxalbert1996 / Scrollbar.kt
Last active April 27, 2024 15:08
Modifiers to draw scrollbars in Jetpack Compose
/*
* MIT License
*
* Copyright (c) 2022 Albert Chang
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@bwbaugh
bwbaugh / server-name-wordlist-mnemonic.txt
Last active April 27, 2024 15:08
Server name wordlist (mnemonic)
# Original blog post: <https://mnx.io/blog/a-proper-server-naming-scheme/>
# Original word list: <http://web.archive.org/web/20091003023412/http://tothink.com/mnemonic/wordlist.txt>
# Sample usage: `curl <gist> | tail --lines +4 | shuf | head --lines 1`
acrobat
africa
alaska
albert
albino
album
alcohol
@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active April 27, 2024 15:07
Complete Recent Discord Quest

Complete Recent Discord Quest

Note

This no longer works in browser!

Note

This no longer works if you're alone in vc! Somebody else has to join you!

How to use this script:

  1. Accept the quest under User Settings -> Gift Inventory
@Raukze
Raukze / contact-sensor-left-open-notification.yaml
Last active April 27, 2024 15:06
Home Assistant Blueprint: Contact Sensor Left Open Notification
blueprint:
name: πŸšͺ Contact Sensor Left Open Notification by Malte
description: |
πŸ“² Notifies you when a door or window is left open.
πŸš€ Version 2024.04.23.1
Are you tired of worrying about open doors or windows? This blueprint has got you covered! It's designed to send you a prompt notification when a door or window remains open for a specified duration.
πŸ“– For Details see this [Blog post](https://community.home-assistant.io/t/contact-sensor-door-or-window-left-open-notification/652571)
@rougier
rougier / nano-org-wip.el
Created April 27, 2024 13:45
GNU Emacs / N Ξ› N O org mode
;;; nano-org-wip.el --- N Ξ› N O org mode -*- lexical-binding: t -*-
;; Copyright (C) 2024 Nicolas P. Rougier
;; Maintainer: Nicolas P. Rougier <Nicolas.Rougier@inria.fr>
;; This file is not part of GNU Emacs.
;; This file is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 3, or (at your option)
@primaryobjects
primaryobjects / hotspot-keep-alive.ps1
Last active April 27, 2024 15:05
Script to Enable Windows 10 Mobile Hotspot Automatically After Reboot
# https://superuser.com/a/1434648
Add-Type -AssemblyName System.Runtime.WindowsRuntime
$asTaskGeneric = ([System.WindowsRuntimeSystemExtensions].GetMethods() | ? { $_.Name -eq 'AsTask' -and $_.GetParameters().Count -eq 1 -and $_.GetParameters()[0].ParameterType.Name -eq 'IAsyncOperation`1' })[0]
Function Await($WinRtTask, $ResultType) {
$asTask = $asTaskGeneric.MakeGenericMethod($ResultType)
$netTask = $asTask.Invoke($null, @($WinRtTask))
$netTask.Wait(-1) | Out-Null
$netTask.Result
@SebaUbuntu
SebaUbuntu / README.md
Last active April 27, 2024 15:05
Generate framework compatibility matrix from fqnames

Generate framework compatibility matrix from fqnames

  • Download these 2 files
  • Compile AOSP without fcm from stock and wait for check_vintf to error out
  • Delete Python prefix from all lines (e.g. checkvintf E 06-24 00:30:22 49120 49120 check_vintf.cpp:554])
  • Paste the result in fqnames.txt
  • Launch the script
@jerodg
jerodg / windows_and_office_kms_setup.adoc
Last active April 27, 2024 15:05
Activate Windows and Office Using KMS Server

Microsoft Windows and Office KMS Setup

@deleugpn
deleugpn / DuskServeCommand.php
Last active April 27, 2024 15:04
Run php artisan serve before running php artisan dusk in a single console command.
<?php
namespace App\Console\Commands;
use RuntimeException;
use Laravel\Dusk\Console\DuskCommand;
use Symfony\Component\Process\Process;
use Symfony\Component\Process\ProcessBuilder;
class DuskServeCommand extends DuskCommand {
@FreddieOliveira
FreddieOliveira / docker.md
Last active April 27, 2024 15:03
This tutorial shows how to run docker natively on Android, without VMs and chroot.

Docker on Android πŸ‹πŸ“±

Edit πŸŽ‰

All packages, except for Tini have been added to termux-root. To install them, simply pkg install root-repo && pkg install docker. This will install the whole docker suite, left only Tini to be compiled manually.


Summary