Posts
Reverting remote git to a specific previous commit
git reset --hard 998c5d24f1b5b4920c6cbbae2e0bc6f9d04513a6 git push --forceGit ignore config file after commiting repository
Ignore config.json git add config.json git commit git push git update-index --assume-unchanged config.json Update config.json git update-index --no-assume-unchanged config.json git commit -a git update-index --assume-unchanged config.jsonMenghapus Semua HTML Entities Pada Text Menggunakan JavaScript Regex
Karakter special umumnya dikonversi menjadi HTML ENTITIES agar dapat ditampilkan pada dokumen HTML. Namun ada kalanya kita tidak membutuhkannya dan ingin menghapus semuanya. Berikut contoh cara menghapusnya dengan menggunakan JavaScript Regex. const catatan = "Copyright © 2024" const hasil = catatan.replace(/&[^>]*;/g,"") console.log(hasil) //Copyright 2024 Regex diatas akan mencari semua kata...Create a new empty branch in Git
$ git checkout --orphan NEWBRANCH $ git rm -rf .Reset local git repo
git remote add origin https://github.com/nuzulul/nuzulul.github.io git fetch --all git reset --hard origin/mainGit - Clear All Git History
Clear Git history by removing all commits git checkout --orphan temp_branch git add -A git commit -am "The first commit" git branch -D main git branch -m main git push -f origin main Referensi : https://www.shellhacks.com/git-remove-all-commits-clear-git-history-local-remote/Unable to load the EventMachine C extension; To use the pure-ruby reactor, requi re 'em/pure_ruby'
Masalah : Setelah melakukan perintah “bundle update” jekyll tidak bisa dijalankan dan muncul error EventMachine seperti dibawah ini : E:\data\github\nuzulul.github.io>bundle exec jekyll serve --future --livereload Configuration file: E:/data/github/nuzulul.github.io/_config.yml Source: E:/data/github/nuzulul.github.io Destination: E:/data/github/nuzulul.github.io/_site Incremental build: disabled. Enable with --incremental Generating... Jekyll Feed: Generating feed for posts done in 1.441 seconds. Auto-regeneration:...
subscribe via RSS