Skip to content

Instantly share code, notes, and snippets.

@ctokheim
ctokheim / sam_bam_tricks.sh
Created March 13, 2015 20:09
SAM/BAM tricks
#########################################
# Convert Sam to Bam with a header:
# -b output bam
# -S input sam
#########################################
samtools view -bS sample.sam > sample.bam
#########################################
# convert Sam to Bam without a header
# -b output bam
{
"dns": {
"servers": [
{
"tag": "dns_proxy",
"address": "https://google.dns/dns-query",
"address_resolver": "dns_resolver",
"strategy": "ipv4_only",
"detour": "proxydns"
},
@troykelly
troykelly / INTEGRATION.md
Last active May 2, 2024 10:51
Automatically mount rclone mounts

Automatic Rclone Mounting and Unmounting on macOS

Prerequisites

  • rclone configured with remotes.
  • The mounting script is properly set up.
  • brew package manager for installing sleepwatcher.

Steps

@veloii
veloii / README.md
Last active May 2, 2024 10:51
raycast-like wofi config

Wofi command to run:

wofi --width=900 --height=500 --gtk-dark -a --allow-images --show drun

@dhh
dhh / linux-setup.sh
Last active May 2, 2024 10:49
linux-setup.sh
# CLI
sudo apt update -y
sudo apt install -y \
git curl \
docker.io docker-buildx \
build-essential pkg-config autoconf bison rustc cargo clang \
libssl-dev libreadline-dev zlib1g-dev libyaml-dev libreadline-dev libncurses5-dev libffi-dev libgdbm-dev libjemalloc2 \
libvips imagemagick libmagickwand-dev mupdf mupdf-tools \
redis-tools sqlite3 libsqlite3-0 libmysqlclient-dev \
rbenv apache2-utils
@mobzystems
mobzystems / 7-zip.psm1
Last active May 2, 2024 10:49
7-Zip commands for PowerShell
<#
Powershell Module 7-Zip - 7-Zip commands for PowerShell
The functions in this module call 7za.exe, the standAlone version of 7-zip to perform various tasks on 7-zip archives.
Place anywhere, together with 7za.exe and 7zsd.sfx. 7za.exe is required for all operations; 7zsd.sfx for creating self
extracting archives.
http://www.7-zip.org
Import-Module [Your path\]7-Zip

1. 如何確認自己是使用Wayland工作階段

使用echo $XDG_SESSION_TYPE即可得知是x11還是wayland

KDE登入畫面SDDM左下角點選Plasama (Wayland)工作階段

GNOME 42後已預設使用GNOME,登入時GDM右下角齒輪會有GNOMEGNOME on Xorg的選項。

2. 強制瀏覽器使用純Wayland工作階段

@bkanhu
bkanhu / beginners_ubuntu.md
Last active May 2, 2024 10:47
A Beginners Guide on Things To Do After Installing Ubuntu.

Beginners Ubuntu

A Beginners Guide To Things To Do After Installing Ubuntu.

1. Check For Updates

sudo apt update && sudo apt upgrade

2. Enable additional repositories for more software

Ubuntu has several repositories from where it provides software for your system. Enabling all these repositories will give you access to more software and proprietary drivers.

@marcorieser
marcorieser / Format Antlers, Blade, Vue, Tailwind and PHP with Prettier in PhpStorm.md
Last active May 2, 2024 10:44
Format Antlers, Blade, Vue, Tailwind and PHP with Prettier in PhpStorm

Install dependencies

Run npm install -D prettier prettier-plugin-antlers prettier-plugin-blade prettier-plugin-tailwindcss @prettier/plugin-php in your terminal

Configure prettier

Create a .prettierrc file with the following content

{
  "singleQuote": true,
  "trailingComma": "all",
  "printWidth": 140,
@niksumeiko
niksumeiko / disable-html-form-input-autocomplete-autofill.md
Last active May 2, 2024 10:43
Disable HTML form input autocomplete and autofill

Disable HTML Form Input Autocomplete and Autofill

  1. Add autocomplete="off" onto <form> element;
  2. Add hidden <input> with autocomplete="false" as a first children element of the form.
<form autocomplete="off" method="post" action="">
    <input autocomplete="false" name="hidden" type="text" style="display:none;">
    ...