Skip to content

Instantly share code, notes, and snippets.

View katagaki's full-sized avatar
🤹
多忙

katagaki

🤹
多忙
  • Tokyo, Japan
  • 18:20 (UTC +09:00)
View GitHub Profile
@ObuchiYuki
ObuchiYuki / VariableBlurView.swift
Last active June 15, 2025 08:02
SwiftUI Progressive / Variable Blur View (using private api)
//
// VariableBlurView.swift
// MFileViewer
//
// Created by yuki on 2025/04/21.
//
import SwiftUI
import UIKit
import CoreImage
@j0lol
j0lol / style.css
Last active November 27, 2024 17:59
Beeper compact sidebar
/*
Gist link for desktop users: https://gist.github.com/j0lol/9674befc870e2b62fe9a24fe29ef9e1a
Made by @j0lol:beeper.com. For support, message me on Beeper or at https://j0.lol
*/
/* Shorten room height */
.rooms_scroll-container ._2iYRbtxMK350NUKTyKq6TP {
height: 32px;
}
@apisandipas
apisandipas / De-quarantine an app on MacOS
Last active December 28, 2024 22:20
De-quarantine an app on MacOS
codesign --sign - --force --deep /Applications/VSCodium.app
xattr -d com.apple.quarantine /Applications/VSCodium.app
@Phenomite
Phenomite / cy.exist conditional testing.js
Created May 1, 2020 01:20
cy.exist function to allow existence checking conditional testing
// Anti-pattern conditional testing with Cypress
// Uses jQuery functionality to determine existence
// Add to your support folder
Cypress.Commands.add("exist", (selector) => {
cy.get('body').should('exist').then(($body) => {
return new Cypress.Promise((resolve, reject) => {
if ($body.find(selector).length > 0) {
console.log("cy.exist() - Matching element found in DOM!");
resolve(true);
@IanColdwater
IanColdwater / twittermute.txt
Last active June 15, 2025 16:53
Here are some terms to mute on Twitter to clean your timeline up a bit.
Mute these words in your settings here: https://twitter.com/settings/muted_keywords
ActivityTweet
generic_activity_highlights
generic_activity_momentsbreaking
RankedOrganicTweet
suggest_activity
suggest_activity_feed
suggest_activity_highlights
suggest_activity_tweet
@mihow
mihow / load_dotenv.sh
Last active July 18, 2025 07:10
Load environment variables from dotenv / .env file in Bash
# The initial version
if [ ! -f .env ]
then
export $(cat .env | xargs)
fi
# My favorite from the comments. Thanks @richarddewit & others!
set -a && source .env && set +a
@zacwest
zacwest / ios-font-sizes.swift
Last active July 24, 2025 22:08
iOS default font sizes - also available on https://www.iosfontsizes.com
let styles: [UIFont.TextStyle] = [
// iOS 17
.extraLargeTitle, .extraLargeTitle2,
// iOS 11
.largeTitle,
// iOS 9
.title1, .title2, .title3, .callout,
// iOS 7
.headline, .subheadline, .body, .footnote, .caption1, .caption2,
]
@joepie91
joepie91 / vpn.md
Last active July 17, 2025 17:03
Don't use VPN services.

Don't use VPN services.

No, seriously, don't. You're probably reading this because you've asked what VPN service to use, and this is the answer.

Note: The content in this post does not apply to using VPN for their intended purpose; that is, as a virtual private (internal) network. It only applies to using it as a glorified proxy, which is what every third-party "VPN provider" does.

  • A Russian translation of this article can be found here, contributed by Timur Demin.
  • A Turkish translation can be found here, contributed by agyild.
  • There's also this article about VPN services, which is honestly better written (and has more cat pictures!) than my article.
@brson
brson / gist:9dec4195a88066fa42e6
Last active June 26, 2025 11:11
A Rust Syntax Guide

A Guide to Rust Syntax

A very brief guide to Rust syntax. It assumes you are already familiar with programming concepts.

This was written in 2014. It is not a good reference for Rust today, though the content is still correct.

cheats.rs looks like a good alternative.

Assert macro

@mshafrir
mshafrir / states_hash.json
Created May 9, 2012 17:05
US states in JSON form
{
"AL": "Alabama",
"AK": "Alaska",
"AS": "American Samoa",
"AZ": "Arizona",
"AR": "Arkansas",
"CA": "California",
"CO": "Colorado",
"CT": "Connecticut",
"DE": "Delaware",