Skip to content

Instantly share code, notes, and snippets.

View drannex42's full-sized avatar
🤖
Replicant? More likely than you would think.

Macleod Sawyer drannex42

🤖
Replicant? More likely than you would think.
View GitHub Profile
@drannex42
drannex42 / check_env.odin
Last active October 29, 2024 16:14
Environment File (.env) Reader [Odin]
// Two options:
// Option 1: set a struct that stores the values,
// Option 2: Use the native Environment Variable options:
// https://pkg.odin-lang.org/core/os/#set_env
// Option 1:
Global_Env :: struct {
USER: string,
PWD: string
}
/* Custom Styles */
#titlebar {
appearance: none !important;
}
#sidebar-header {
padding: 5px 8px !important;
padding-top: 11px !important;
}
---json
{
"permalink": "feed.xml",
"layout": "clear",
"eleventyExcludeFromCollections": true,
"metadata": {
"title": "Drannex42 | Web Portal Feed",
"subtitle": "The personal website of Macleod Sawyer, Director (CEO) of DNX Industries, known primarily online as Drannex42.",
"url": "https://drannex42.com/",
"feedUrl": "https://drannex42.com/feed.xml",

D web development package

These are some recommended D web development packages from Dub you may need. These following are choosing because I've either personally used them or they have good documentation.

Any recommendation? Please let me know in the comments.

Web frameworks

  • vibe-d (its like Express.js from Node.js/Javascript)
  • hunt-framework (its like Laravel from PHP)

Json parsing and serialization

Download Audio from YouTube

-i - ignore errors

-c - continue

-t - use video title as file name

--extract-audio - extract audio track

Keybase proof

I hereby claim:

  • I am drannex42 on github.
  • I am drannex42 (https://keybase.io/drannex42) on keybase.
  • I have a public key whose fingerprint is 2C59 55CF 1C29 14A8 F299 1142 55B2 5718 C365 6B6D

To claim this, I am signing this object:

Keybase proof

I hereby claim:

  • I am macleodsawyer on github.
  • I am macleod (https://keybase.io/macleod) on keybase.
  • I have a public key ASA0FTHZZbddJxlt1SlkVz656JPaZrYqJ2MuucExLTNePwo

To claim this, I am signing this object:

</div>
</div>
<center>
<h2><a href="http://instagram.com/horrified"><img alt="Follow me on Instagram!" src="http://i.imgur.com/AQrNZcW.gif" style="width: 198px; height: 26px; left:20px;" /></a></h2></center
colors = {};
colors['ca'] = '#A4D886';
colors['ru'] = '#FCECA2';
colors['cn'] = '#F9573B';
colors['us'] = '#87CEEB';
colors['jp'] = '#34BD0E';
colors['au'] = '#BCC7FC';
colors['kz'] = '#D4624E';
colors['de'] = '#34BD0E';