Skip to content

Instantly share code, notes, and snippets.

View kaushalmodi's full-sized avatar

Kaushal Modi kaushalmodi

View GitHub Profile
@lukas-h
lukas-h / license-badges.md
Last active March 28, 2024 10:06
Markdown License Badges for your Project

Markdown License badges

Collection of License badges for your Project's README file.
This list includes the most common open source and open data licenses.
Easily copy and paste the code under the badges into your Markdown files.

Notes

  • The badges do not fully replace the license informations for your projects, they are only emblems for the README, that the user can see the License at first glance.

Translations: (No guarantee that the translations are up-to-date)

@font-face {
font-family: 'Linux Libertine'; /* normal */
src: url('/static/fonts/linux-libertine/LinLibertine_R.woff') format('woff');
font-weight: normal;
font-style: normal;
}
@font-face {
font-family: 'Linux Libertine'; /* italic */
src: url('/static/fonts/linux-libertine/LinLibertine_RI.woff') format('woff');
@plaidfinch
plaidfinch / pretty-pragmata.el
Last active July 15, 2021 01:56
Mappings for prettify-symbols-mode to enable Pragmata Pro's ligatures in Emacs. I've taken some slight liberties with the original ligature map, to suit my own tastes.
;; PRETTIFY SYMBOLS (with Pragmata Pro)
(defun setup-pragmata-ligatures ()
(setq prettify-symbols-alist
(append prettify-symbols-alist
'(("!!" . ?)
("!=" . ?)
("!==" . ?)
("!≡" . ?)
("!≡≡" . ?)
("!>" . ?)
@lpar
lpar / README.md
Last active January 29, 2023 14:09
How to make Hugo (0.20+) generate an Atom feed instead of RSS

The Hugo static site generator sadly still uses the obsolete and badly standardized RSS format.

Here's how to set it up to generate an Atom feed instead. Pretty much all feed readers which understand RSS also understand Atom, except iTunes, and Atom is a better format.

  1. Define an appropriate media type and corresponding output format in config.toml:
@dmyates
dmyates / description-list.html
Last active September 4, 2023 09:43
Simple description list shortcode for use with the Hugo static site generator.
{{ .Get 0 | replaceRE "<ul>" "<dl>" .Inner | replaceRE "</ul>" "</dl>" | replaceRE "<li>" "<dt>" | replaceRE "(<dt>.*?): " "$1</dt><dd>" | replaceRE "</li>" "</dd>" | markdownify }}
@kaushalmodi
kaushalmodi / debugprint.html
Last active July 11, 2023 01:03
Pretty printing Hugo variables for debug
Thanks for stopping by.
This code has been moved to https://github.com/kaushalmodi/hugo-debugprint as a Hugo theme component.
@eddiewebb
eddiewebb / readme.md
Last active February 12, 2024 08:46
Hugo JS Searching with Fuse.js

Git orphan branches & working trees

Creating an ophan branch

This command will create a branch with no parent (no commit history) on a repo.

git checkout --orphan <new-branch>

Managing working trees

Manage folders linked to others branches of your repo. Do not confuse them with git submodules which are links to different repositories.

```
using ripgrep
rg -t nim --no-line-number --no-heading --no-filename --only-matching 'defined\(\w+\)' | sort | uniq | wc -l
363
```
rg -t nim --no-line-number --no-heading --no-filename --only-matching 'defined\(\w+\)' | sort | uniq
```
@Vindaar
Vindaar / aNimKissFFT.org
Last active March 3, 2020 21:08
An example on how to use Kiss FFT in Nim

Another attempt of using kissFFT in Nim

I decided to look at what I did a couple of years ago with kiss FFT and Nim.

My original use case involved FADC (flash ADC; ADC with a sampling frequency of 1 GHz) events from my PhD work, which randomly contained a lot of noise (probably due to EMI).

The FADC has a cyclic register with 2560 elements. My idea was to