Skip to content

Instantly share code, notes, and snippets.

@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active May 10, 2024 08: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
@WillSams
WillSams / m68k_dev_setup.sh
Last active May 10, 2024 08:06
Setup for Motorola 68000 (Sega, Neo Geo) Cross Compiler on Debian-based System
#!/bin/bash
echo "==================================================================="
echo
echo " My m68000 Development Setup "
echo " You may be prompted for root credentials to complete the install. "
echo
echo " Toolchain is GNU so it expects you to write AT&T style assembly. "
echo " If you want the Windows (MSYS2) script, it's here: "
echo " https://gist.github.com/WillSams/f592f9d494b51119945440f7e91079b0 "
@KTakitani
KTakitani / Final_Assignment Library.ipynb
Created May 19, 2021 11:13
Extracting Stock Data Using a Python Library
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@nobuoka
nobuoka / java-for-android-app.markdown
Last active May 10, 2024 08:02
Android アプリ開発勉強会のために書いた Java の入門文書

Android アプリ開発のための Java 入門

MEMO

  • declaration は 「宣言」 と訳しているが、「定義」 の方が適しているような気がしなくもない。
  • 「インスタンス」 と 「オブジェクト」 という言葉を使うことがあるが、本文書中ではどちらも同じ意味で使用している。
  • String オブジェクト」 という表現は、「String クラスのインスタンス」 を意味している。 (Java に限らず一般的な表現だと思う。)

はじめに

@mikedld
mikedld / CMakeLists.txt
Created October 5, 2021 20:46
Find all CMake targets declared in a directory (recursively)
function(print_all_targets DIR)
get_property(TGTS DIRECTORY "${DIR}" PROPERTY BUILDSYSTEM_TARGETS)
foreach(TGT IN LISTS TGTS)
message(STATUS "Target: ${TGT}")
# TODO: Do something about it
endforeach()
get_property(SUBDIRS DIRECTORY "${DIR}" PROPERTY SUBDIRECTORIES)
foreach(SUBDIR IN LISTS SUBDIRS)
print_all_targets("${SUBDIR}")
@wojteklu
wojteklu / clean_code.md
Last active May 10, 2024 07:59
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

@ravenscroftj
ravenscroftj / minimal_continue_groq_config.md
Created April 28, 2024 08:46
Minimal Groq + Continue.Dev Recipe

Minimal continue.dev Groq Config

{
  "models": [
    {
      "title":"Groq Llama 8b",
      "provider":"openai",
      "model": "llama3-8b-8192",
      "apiBase": "https://api.groq.com/openai/v1",
 "apiKey": "",
@davidteren
davidteren / nerd_fonts.md
Last active May 10, 2024 07:58
Install Nerd Fonts via Homebrew [updated & fixed]
@sts10
sts10 / rust-command-line-utilities.markdown
Last active May 10, 2024 07:57
A curated list of command-line utilities written in Rust

A curated list of command-line utilities written in Rust

Note: I have moved this list to a proper repository. I'll leave this gist up, but it won't be updated. To submit an idea, open a PR on the repo.

Note that I have not tried all of these personally, and cannot and do not vouch for all of the tools listed here. In most cases, the descriptions here are copied directly from their code repos. Some may have been abandoned. Investigate before installing/using.

The ones I use regularly include: bat, dust, fd, fend, hyperfine, miniserve, ripgrep, just, cargo-audit and cargo-wipe.

  • atuin: "Magical shell history"
  • bandwhich: Terminal bandwidth utilization tool
@sv99
sv99 / How can I replace a newline (\n) using sed.md
Last active May 10, 2024 07:56
How can I replace a newline (\n) using sed?

stackoverflow (hdorio)

Fast answer:

sed ':a;N;$!ba;s/\n/ /g' file
  1. :a create a label 'a'
  2. N append the next line to the pattern space
  3. $! if not the last line, ba branch (go to) label 'a'
  4. s substitute, /\n/ regex for new line, / / by a space, /g global match (as many times as it can)