Skip to content

Instantly share code, notes, and snippets.

View acfatah's full-sized avatar
🎯
Focusing

Achmad F. Ibrahim acfatah

🎯
Focusing
View GitHub Profile
@acfatah
acfatah / bash_strict_mode.md
Created April 1, 2023 02:33 — forked from vncsna/bash_strict_mode.md
set -e, -u, -o, -x pipefail explanation

set -e, -u, -o, -x pipefail

The set lines

  • These lines deliberately cause your script to fail. Wait, what? Believe me, this is a good thing.
  • With these settings, certain common errors will cause the script to immediately fail, explicitly and loudly. Otherwise, you can get hidden bugs that are discovered only when they blow up in production.
  • set -euxo pipefail is short for:
set -e
set -u

JavaScript Modules

  1. How do I make the tree shakeable?
  2. What JS module systems should I target (CommonJS, AMD, ES6).
  3. Should I transpile the source?
  4. Should I bundle the source?
  5. What files should I publish?

Let's try to address all the above questions now.

@acfatah
acfatah / - acfatah Git Activities.md
Last active July 18, 2025 23:33
Gist Image Hosting

Git Image Hosting using Gist Comment

@acfatah
acfatah / bun-lint-test-typecheck.yml
Created March 7, 2025 00:09 — forked from morajabi/bun-lint-test-typecheck.yml
Bun test, lint, and typecheck your Bun project in GitHub actions with caching
# .github/workflows/test.yml
on:
push:
branches:
- main
pull_request:
branches:
- main
@acfatah
acfatah / mongodb_6_on_wsl2_ubuntu_2204.md
Created September 4, 2025 22:14 — forked from leobeeson/mongodb_6_on_wsl2_ubuntu_2204.md
Installation of MongoDB 6.0 on WSL2 Ubuntu 22.04

Installation of MongoDB 6.0 on WSL2 Ubuntu 22.04

Installed MongoDB using the following guide: Install MongoDB

However, the installation in the guide is for MongoDB 5.0 on WSL with Ubuntu 20.04 (focal) distro.

The following is an adaptation of the guide for installing MongoDB 6.0 on WSL with Ubuntu 22.04 jammy distro.

  1. Open your WSL terminal (ie. Ubuntu) and go to your home directory:: cd ~
  2. Update your Ubuntu packages: sudo apt update