diff --git a/.gitignore b/.gitignore old mode 100755 new mode 100644 diff --git a/.markdown-preview.html b/.markdown-preview.html old mode 100755 new mode 100644 diff --git a/.projectile b/.projectile new file mode 100644 index 0000000..744770c --- /dev/null +++ b/.projectile @@ -0,0 +1,5 @@ +-.packages/ +-*~ +-output/ +-DS_Store +-backups/ \ No newline at end of file diff --git a/20241210004247-emacs_stuff.org b/20241210004247-emacs_stuff.org deleted file mode 100755 index 8db62c3..0000000 --- a/20241210004247-emacs_stuff.org +++ /dev/null @@ -1,26 +0,0 @@ -:PROPERTIES: -:ID: 8fa3f476-6152-45f4-b618-50f1e4bce46c -:END: -#+title: emacs_moc -#+filetags: :emacs:moc: - -The purpose of this file is to store things related to emacs (that being packages, or community projects that i stumble across). -- [[id:034abe27-ca14-4dc0-9a3f-b8d0e1f26342][emacs-stuff-org-roam]] for roam related things -- [[id:8e5e9498-ff3c-48e7-aab5-6e94b2e41ccb][emacs-stuff-gtd]] -- [[id:966175d4-3b58-4abc-9b41-08cbf328dd87][emacs-stuff-keybindings]] -- [[id:7e79e4c5-383d-450f-882c-33d4f87ba1b5][emacs-stuff-elisp]] -- [[id:2ab0fa3f-8ac6-4af2-8cd4-1dd490fb19c3][emacs-stuff-magit]] -- [[id:45CC3AF5-5E20-4B03-A36C-8D4BDD5CBB13][emacs-stuff-evil]] -[[id:7d2e867e-f091-4362-a583-453f732207fe][emacs-stuff-org-publish]] - -- A link that contains all the key bindings for emacs: [[http://xahlee.info/emacs/emacs/emacs_keybinding_list.html][Keybindings list]] -- the theme 'ef-dream' repository: [[https://github.com/protesilaos/ef-themes][ef-themes]] -- something to look into: [[https://github.com/mickeynp/combobulate][combobulate]] -- the use package git hub: [[https://github.com/jwiegley/use-package][use-package]] -- hamacs (someones emacs config) [[https://www.howardabrams.com/hamacs/][hamacs]] -- projectile doc [[https://docs.projectile.mx/projectile/configuration.html][proj doc]] -- doom style dashboard [[https://gist.github.com/DevelopmentCool2449/ffc91d1d9b7b16e0f48402b698386f3d#file-dashboard-doom-style-el][doom dash]] -- soft charcoal theme [[https://github.com/mswift42/soft-charcoal-theme?tab=readme-ov-file][sc]] -- the theme im currently using: [[https://github.com/ogdenwebb/emacs-kaolin-themes?tab=readme-ov-file][kaolin]] -- config: [[https://gitlab.com/dwt1/configuring-emacs][config-dwt]] -- simplenote to self hosted: [[https://ru2saig.github.io/posts/switching-from-simplenote-to-a-self-hosted-approach-nextcloud-orgzly-and-emacs/][Link]] diff --git a/20241210152650-uni.org b/20241210152650-uni.org deleted file mode 100755 index 7987481..0000000 --- a/20241210152650-uni.org +++ /dev/null @@ -1,12 +0,0 @@ -:PROPERTIES: -:ID: 797d6e3e-98eb-4bc7-88b6-e096ef7306ad -:END: -#+title: uni_moc -#+filetags: :uni:moc: -* Modules: -- [[id:5443ed1c-bb7f-4eb4-9c96-d12648dd2291][tpis]] -- [[id:556d10d1-1c74-4d9f-a398-39cb3bd5d935][afp]] -- [[id:c69e4c4d-2fb4-4cf1-a835-a235cf6db8e9][ise]] -- [[id:3acffb66-bc1a-4661-904f-c5447b3c3488][advanced-networking]] -* Final Year Project -- [[id:7d199fbe-b0e7-48fd-b8a1-793044dbea01][fyp]] Final Year Project diff --git a/20241210233721-brain_moc.org b/20241210233721-brain_moc.org old mode 100755 new mode 100644 diff --git a/20250120110833-afp.org b/20250120110833-afp.org deleted file mode 100755 index 85de8f2..0000000 --- a/20250120110833-afp.org +++ /dev/null @@ -1,11 +0,0 @@ -:PROPERTIES: -:ID: 556d10d1-1c74-4d9f-a398-39cb3bd5d935 -:END: -#+title: afp -#+filetags: :uni:index: - -[[id:6c272430-aff5-468b-90d3-5ff3a96152cf][afp_week1]] - -[[id:4bc71106-1d2b-4c71-836d-54b738fe5ff5][afp_week2]] - -[[id:1f395b8c-cf55-43eb-9430-dd9449f6b575][afp_week5]] diff --git a/20250723182408-so_good_they_cant_ignore_you.org b/20250723182408-so_good_they_cant_ignore_you.org deleted file mode 100755 index 7d7eb41..0000000 --- a/20250723182408-so_good_they_cant_ignore_you.org +++ /dev/null @@ -1,76 +0,0 @@ -:PROPERTIES: -:ID: 2d7f1ccc-99d7-4c45-8fe7-4b87080edb01 -:TYPE: Book -:AUTHOR: Cal Newport -:DATE_STARTED: <2025-05-25 Sun> -:DATE_ENDED: <2025-06-15 Sun> -:END: -#+title: so_good_they_cant_ignore_you -#+filetags: :books: - -* So good they cant ignore you -Some of these points have been inspired from this -[[https://jasonkwanhc.medium.com/book-summary-of-so-good-they-cant-ignore-you-58cb236fef0d][website]] - -* Summary - -The book focuses on the reality of how people end up loving what they do. It demystifies the concept: "follow your -passion", and details alternative strategies. - -** Rule *1: **Don’t Follow Your Passion** - -1. The Passion Hypothesis is the biggest myth in occupational happiness. It says that “The key to occupational happiness - is to first figure out what you are passionate about and then find a job that matches this passion”, the author1 - argues against this. -2. He mentions some incidents of people like Steve Jobs, proving that successful people like him (who is famous for the - concept "follow your passions") didn’t start off because he had a passion for the thing they do. - -** Rule *2: Be So Good They Can’t Ignore You (Or, the importance of skills) - -1. The traits that define great work are rare and valuable, if you want these traits, you need rare and valuable skills. - These skills are called *[[id:f9838952-9753-471b-a2cc-d72e01a53ef6][career-capital]]*. -2. Adopt the **Craftsman Mindset** where instead you focus on what you can offer the world. This is in stark contrast to - the **Passion Mindset** where you focus on what the world can offer you. The craftsman mindset focuses on becoming - better and improving the quality of what you produce. It focuses on becoming so good they can’t ignore you, - regardless of what you do for a living. -3. The concept of *[[id:d4f96bfb-b83d-449b-9f74-f602a1a3c2d3][deliberate-practice]]* is mentioned where you deliberately stretch your - abilities beyond where you're comfortable and then receive ruthless feedback on your performance. -4. 5 Steps on applying the deliberate practice in your work: - - 1. **Step 1: Decide What Type of Capital Market You’re Competing In.** There are two kinds of markets, a - *winner-take-all* market and an *auction* market. In a winner-take-all market, there's only one type of career - capital available and only one that matters. In the auction market however, there are a variety of relevant - skills that could *lead* you to getting the job, in other words, there are a variety of career capital available. - 2. **Step 2: Identify Your Capital Type**. This step makes you figure out what are the relevant skills that are - needed in order to be great at your job. In the winner-take-all market, it's pretty straightforward that it's - that one career capital, however in the auction market there's more flexibility. A useful heuristic mentioned is - the *open-gates* opportunities present. In other words, those opportunities to build capital that are already - open to you, then you work your way up. - 3. **Step 3: Define “Good”** . Having a clear view of what *good* means is important. This step forces you to think - about where you want to be and how you can achieve it using deliberate practice. This definition will be - different for different people. - 4. **Step 4: Stretch and Destroy**. Deliberate practice requires you to be uncomfortable, as it is something that is - not enjoyable. The important thing is to push beyond your comfort zone and get immediate feedback to steer you in - the right direction. - 5. **Step 5: Patience**. The acquisition of career capital will take time, therefore, it is necessary to be patient - and ensure that you pour all your effort into the capital you seek. The final sentence given in the book before - the summary is: **You stretch yourself, day after day, month after month, before finally looking up and - realising, "Hey, I've become pretty good, and people are starting to notice".** - -** Rule *3: Turn Down a Promotion (Or, the importance of control) - -1. The author here explains that once you've acquired a certain amount of career capital, your next step is to invest -in those traits that define great work. Discussion was made about control, and the common pitfalls that people fall -into. -2. The law of financial viability: when pursuing a project or career path, it's crucial to seek evidence that people - are willing to pay for it. If that evidence exists, it's a good sign to proceed; if not, it's better to reconsider or pivot. - -** Rule *4: Think Small, Act Big (Or, the importance of Mission) - -1. This rule focuses on the importance of having a mission in your work. Having a unifying focus for your career, a - sense of purpose, can make your work more meaningful and impactful. -2. A good career mission is similar to a scientific breakthrough, discovered in the adjacent possible of your field. - You will need to acquire enough career capital to be able to get into the *cutting edge* of your field. Once you - get into this cutting edge, you can then start to see these missions. -3. Think small, act big. Instead of focusing on a huge experiment with little feedback, focus on small experiments - that yield concrete feedback, and use this to guide you into the direction surrounding your general mission. diff --git a/20250723184233-advanced_networking.org b/20250723184233-advanced_networking.org deleted file mode 100755 index a709b2b..0000000 --- a/20250723184233-advanced_networking.org +++ /dev/null @@ -1,29 +0,0 @@ -:PROPERTIES: -:ID: 3acffb66-bc1a-4661-904f-c5447b3c3488 -:END: -#+title: advanced-networking -#+filetags: :uni:networking: - -# Advanced Networking - -This module was taught in the first semester of my final year at university. There were a wide range of topics that were covered, and best efforts were made in not talking about the security aspects of networks, although it is the case that when we talk about networks we are talking about secure networks (who even needs insecure networks?). - -The following core topics were covered: - -1. Lower Layer Protocols - - Packet vs Circuit Switching, Ethernet, layer models (DoD 4/5, OSI 7). - - Network Hardware: Switches, Routers, data/control/management plane. Software defined networks. - - LAN/WAN split, Arpanet, DoD, OSI. Why OSI Failed - - Link aggregation and VLANs -2. IP Addressing - - Addressing, routing, concepts. Why IPv6 is needed - - Address allocation, bootp, DHCP, SLAAC - - NAT and Proxying -3. TCP/UDP - - UDP: applications, advantages and disadvantages - - TCP: applications, advantages and disadvantages, mechanisms and operation, sequence numbers, receive windows, slow start, window scaling, PAWS, timestamping, multipathing - - Demultiplexing, multiplexing -4. DNS - - DNS: concepts, resource records, RR sets, basic operation, recursive and authoritative servers, caching, DNSSEC -5. Higher layer protocols - - Basic operation of HTTP, FTP, SMTP diff --git a/20260121173318-api_architecture.org b/20260121173318-api_architecture.org deleted file mode 100755 index 552802e..0000000 --- a/20260121173318-api_architecture.org +++ /dev/null @@ -1,6 +0,0 @@ -:PROPERTIES: -:ID: 49b195c8-e116-40ca-86e8-62c65dbb5a4f -:END: -#+title: API Architecture -#+filetags: :notes:concepts:api: - diff --git a/20260327110908-api_intro_notes.org b/20260327110908-api_intro_notes.org new file mode 100644 index 0000000..663e84d --- /dev/null +++ b/20260327110908-api_intro_notes.org @@ -0,0 +1,175 @@ +:PROPERTIES: +:ID: e7f082e4-1b9f-4ebe-96d6-94d92e80a07e +:END: +#+title: API Intro Notes + +**Notes from [[https://app.pluralsight.com/ilx/video-courses/apis-explained/course-overview][PluralSight]]** + +* APIs Are Everywhere +- APIs power everyday digital experiences behind the scenes. +- They connect apps, data, and services seamlessly. +- Examples: + - Checking weather + - Banking apps + - Booking travel + - Sharing music +- APIs act as *connectors* between systems. + +** Key Idea +APIs = invisible infrastructure enabling modern apps. + +* Real-World API Examples +- Google Maps -> location, routing +- Stripe -> payments +- OpenWeather -> weather data +- Spotify -> music data & activity + +** Insight +- APIs are often *products themselves*. +- They act as *building blocks* for faster development. + +* What Is an API? +** Definition +API (Application Programming Interface): +- A way for systems to communicate +- Sends requests and receives responses +- Hides internal complexity + +** Restaurant Analogy +- You -> Client +- Menu -> API documentation +- Waiter -> API +- Kitchen -> System/service +- Meal -> Response + +** Core Components +- Request -> what is asked +- Response -> returned result +- Endpoint -> where request is sent +- Payload -> data sent with request +- Format -> structure (e.g., JSON, XML) + +* Why APIs Matter +- Speed -> build faster using existing services +- Reuse -> avoid rebuilding functionality +- Focus -> teams specialize and connect via APIs + +* Example: Travel App +- Flight API -> routes/prices +- Hotel API -> availability +- Weather API -> forecasts +- Payment API -> transactions + +** Insight +Multiple APIs -> one seamless user experience. + +* APIs in Modern Architecture +- Composability -> systems built from smaller parts +- Ecosystems -> partnerships & integrations +- AI -> APIs provide data + deliver outputs + +* What APIs Are NOT +- Not just for engineers +- Not a database (they access data, don't store it) +- Not a UI (they work behind the scenes) +- Not always public (many are internal) + +** Analogy +- App = stage +- API = backstage operations + +* How APIs Work +** Process +1. Request sent to endpoint +2. System processes request +3. Response returned + +** Data Handling +- Data is structured and standardized +- Travels in small packets +- Uses agreed formats + +** Impact +- Automation of tasks +- Cross-device consistency +- Scalability + +* APIs Inside a Business +- Internal APIs connect teams and systems +- Enable modular architecture + +** Benefits +- Faster development +- Single source of truth +- Scalability +- Team independence + +** Example +Travel app: +- Flights, Hotels, Cars, Payments -> separate services +- APIs unify them into one experience + +* API as a Product +** Concept +- Companies expose APIs for external use +- Creates ecosystems and new revenue streams + +** Example: Google Maps +- Released API (2005) +- Enabled: + - Ride-sharing (Uber) + - Travel platforms + - Real estate apps + - Games (Pokmon Go) + +** Key Lessons +- Solve internal problem first +- Package as a product +- Enable external innovation +- Build ecosystems + +** Other Examples +- Stripe -> payments +- Twilio -> communication APIs +- AWS -> cloud infrastructure +- Dropbox -> file storage APIs + +* API Pitfalls +** Challenges +- Complexity increases with scale +- Dependency on external services +- Internal dependencies between teams + +** Risks +- Downtime from third-party APIs +- Breaking changes +- Cost spikes (pay-as-you-go) + +** Mitigation +- Rate limiting +- Bot protection +- Usage monitoring & alerts + +* Why APIs Matter for the Future +** Flexibility +- Easy integration of new tools +- Easier vendor switching +- Adaptable systems + +** AI Dependence +- APIs provide: + - Input data + - Output delivery +- Enable real-time, useful AI systems + +** Strategic Importance +- APIs influence: + - Business growth + - Product design + - Partnerships + +* Key Takeaways +- APIs connect systems through requests and responses +- They enable speed, scalability, and innovation +- They are critical for modern software and business strategy +- Thinking in APIs -> better decisions and flexibility diff --git a/20260327114708-asp_net_core_6_apis_notes.org b/20260327114708-asp_net_core_6_apis_notes.org new file mode 100644 index 0000000..2538772 --- /dev/null +++ b/20260327114708-asp_net_core_6_apis_notes.org @@ -0,0 +1,6 @@ +:PROPERTIES: +:ID: b2fd7038-42a8-4cbe-882b-92fbe2c12a11 +:END: +#+title: ASP.NET Core Web API Fundamental Notes + +**Notes from [[https://app.pluralsight.com/ilx/video-courses/asp-dot-net-core-6-web-api-fundamentals/resources][Pluralsight]]** diff --git a/20241231172543-the_science_of_self_discipline.org b/Books/20241231172543-the_science_of_self_discipline.org old mode 100755 new mode 100644 similarity index 100% rename from 20241231172543-the_science_of_self_discipline.org rename to Books/20241231172543-the_science_of_self_discipline.org diff --git a/20250715223949-the_clean_coder.org b/Books/20250715223949-the_clean_coder.org old mode 100755 new mode 100644 similarity index 100% rename from 20250715223949-the_clean_coder.org rename to Books/20250715223949-the_clean_coder.org diff --git a/20250723182408-so-good-they-cant-ignore-you.org b/Books/20250723182408-so-good-they-cant-ignore-you.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723182408-so-good-they-cant-ignore-you.org rename to Books/20250723182408-so-good-they-cant-ignore-you.org diff --git a/20250723183655-career_capital.org b/Books/20250723183655-career_capital.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723183655-career_capital.org rename to Books/20250723183655-career_capital.org diff --git a/20250723183755-deliberate_practice.org b/Books/20250723183755-deliberate_practice.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723183755-deliberate_practice.org rename to Books/20250723183755-deliberate_practice.org diff --git a/20250723184430-stanford_marshmallow_experiment.org b/Books/20250723184430-stanford_marshmallow_experiment.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723184430-stanford_marshmallow_experiment.org rename to Books/20250723184430-stanford_marshmallow_experiment.org diff --git a/20250723185056-neuroplasticity.org b/Books/20250723185056-neuroplasticity.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723185056-neuroplasticity.org rename to Books/20250723185056-neuroplasticity.org diff --git a/20250724230557-books_org_agenda.org b/Books/20250724230557-books_org_agenda.org similarity index 99% rename from 20250724230557-books_org_agenda.org rename to Books/20250724230557-books_org_agenda.org index 9def2d3..20a1af7 100644 --- a/20250724230557-books_org_agenda.org +++ b/Books/20250724230557-books_org_agenda.org @@ -7,7 +7,7 @@ #+filetags: :books:org:index: #+DATE: 2025-05-19 #+STARTUP: content -#+PROPERTY: GENERATED_AT 2026-03-21T00:00:01.182903 +#+PROPERTY: GENERATED_AT 2026-03-27T00:00:01.420902 * Career ** Clean Code_ A Handbook of Agile Software Craftsmanship - Robert C. Martin :Read: diff --git a/20250727174809-books_moc.org b/Books/20250727174809-books_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250727174809-books_moc.org rename to Books/20250727174809-books_moc.org diff --git a/20250727174903-book_recs.org b/Books/20250727174903-book_recs.org old mode 100755 new mode 100644 similarity index 100% rename from 20250727174903-book_recs.org rename to Books/20250727174903-book_recs.org diff --git a/20250727221512-clean_code.org b/Books/20250727221512-clean_code.org old mode 100755 new mode 100644 similarity index 100% rename from 20250727221512-clean_code.org rename to Books/20250727221512-clean_code.org diff --git a/20250722221649-career_moc.org b/Career Concepts/20250722221649-career_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250722221649-career_moc.org rename to Career Concepts/20250722221649-career_moc.org diff --git a/20250723200800-postgres.org b/Career Concepts/20250723200800-postgres.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723200800-postgres.org rename to Career Concepts/20250723200800-postgres.org diff --git a/20250727122406-database_moc.org b/Career Concepts/20250727122406-database_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250727122406-database_moc.org rename to Career Concepts/20250727122406-database_moc.org diff --git a/20250804201706-big_o_complexity.org b/Career Concepts/20250804201706-big_o_complexity.org old mode 100755 new mode 100644 similarity index 98% rename from 20250804201706-big_o_complexity.org rename to Career Concepts/20250804201706-big_o_complexity.org index ad11dea..ab08bab --- a/20250804201706-big_o_complexity.org +++ b/Career Concepts/20250804201706-big_o_complexity.org @@ -1,9 +1,10 @@ :PROPERTIES: :ID: 275988a8-59d8-40c8-a8b4-47118d6eb834 :END: -#+title: big-o-complexity +#+title: Big (O) - Time and Space Complexity #+filetags: :leetcode:notes: #+OPTIONS: toc:t +#+category: Career Concepts * Big (O) - Time and Space Complexity ** Intro @@ -52,8 +53,7 @@ Suppose we are given a problem where we have a list of `N` numbers of unknown le This would take N time, we need to check every number in the list once, making this solution O(N) - linear time. This looks at the worst case scenarion, if 2 was at the start of the list we know it would take a constant time, however if it's at the end then it would take N time. -[[~/master-folder/org_files/org_roam/assets/Big-O-Notation-3130482830.png]] - +[[../assets/Big-O-Notation-3130482830.png]] In the graph above focus on the tail end of the graphs because Big O is concerned with "as the input size grows what happens to the speed of the operations". diff --git a/20251223215636-design_patterns_notes.org b/Career Concepts/20251223215636-design_patterns_notes.org old mode 100755 new mode 100644 similarity index 99% rename from 20251223215636-design_patterns_notes.org rename to Career Concepts/20251223215636-design_patterns_notes.org index 128f7ba..da68fff --- a/20251223215636-design_patterns_notes.org +++ b/Career Concepts/20251223215636-design_patterns_notes.org @@ -3,6 +3,7 @@ :END: #+title: Design patterns #+filetags: :notes:career:technical: +#+category: Career Concepts *WIP* diff --git a/20251229180039-airflow.org b/Career Concepts/20251229180039-airflow.org old mode 100755 new mode 100644 similarity index 100% rename from 20251229180039-airflow.org rename to Career Concepts/20251229180039-airflow.org diff --git a/20251229180156-airflow_tasks.org b/Career Concepts/20251229180156-airflow_tasks.org old mode 100755 new mode 100644 similarity index 100% rename from 20251229180156-airflow_tasks.org rename to Career Concepts/20251229180156-airflow_tasks.org diff --git a/20251229180249-airflow_dags.org b/Career Concepts/20251229180249-airflow_dags.org old mode 100755 new mode 100644 similarity index 100% rename from 20251229180249-airflow_dags.org rename to Career Concepts/20251229180249-airflow_dags.org diff --git a/20260101010049-concepts.org b/Career Concepts/20260101010049-concepts.org old mode 100755 new mode 100644 similarity index 91% rename from 20260101010049-concepts.org rename to Career Concepts/20260101010049-concepts.org index 145265c..40eb365 --- a/20260101010049-concepts.org +++ b/Career Concepts/20260101010049-concepts.org @@ -3,6 +3,7 @@ :END: #+title: Concepts #+filetags: :technical:concepts: +#+category: Career Concepts In this node lies notes relating to theoretical concepts tying with maths and/or computer science. I will need to find a way to categorise different notes, but it's a wip. @@ -20,15 +21,21 @@ Part of being a software engineer is having a good grasp of mathematical concept - [[id:631b2086-4b8f-4fe3-829d-be1dc014e293][Design patterns]] WIP -- [[id:49b195c8-e116-40ca-86e8-62c65dbb5a4f][API Architecture]] WIP - - [[id:2767b5ac-f2c9-4b1e-ab87-82c43cdec4c1][CI/CD Example - Sitevisits]] -- [[id:5b714c6c-7eaf-4f3f-b4f6-2166ff3a9963][CI/CD Summary]] +- [[id:5b714c6c-7eaf-4f3f-b4f6-2166ff3a9963][CI/CD Summary]] + +Some core programming concepts that are essential for software development. The things I need to add here are: + +* APIs - [[id:6a5bf6dd-d0ec-43e4-8e07-9956f4715f10][RESTful API]] -Some core programming concepts that are essential for software development. The things I need to add here are: +- [[id:49b195c8-e116-40ca-86e8-62c65dbb5a4f][API Architecture]] (Just needs spell checks and re read) + +- [[id:e7f082e4-1b9f-4ebe-96d6-94d92e80a07e][API Intro Notes]] + +- [[id:b2fd7038-42a8-4cbe-882b-92fbe2c12a11][ASP.NET Core Web API Fundamental Notes]] * Database Related diff --git a/20260101011126-xor.org b/Career Concepts/20260101011126-xor.org old mode 100755 new mode 100644 similarity index 97% rename from 20260101011126-xor.org rename to Career Concepts/20260101011126-xor.org index 9958524..797c013 --- a/20260101011126-xor.org +++ b/Career Concepts/20260101011126-xor.org @@ -1,8 +1,9 @@ :PROPERTIES: :ID: F32F8F09-3DEC-4FD1-8CFA-401A316E906B :END: -#+title: xor +#+title: XOR #+filetags: :maths:notes: +#+category: Career Concepts XOR stands for exclusive or. It is a logical operation that outputs true only when the inputs differ (one is true, the other is false). If both inputs are the same (both true or both false), the output is false. diff --git a/20260101012549-solid_principles.org b/Career Concepts/20260101012549-solid_principles.org old mode 100755 new mode 100644 similarity index 97% rename from 20260101012549-solid_principles.org rename to Career Concepts/20260101012549-solid_principles.org index a6e8e5f..940a76a --- a/20260101012549-solid_principles.org +++ b/Career Concepts/20260101012549-solid_principles.org @@ -1,8 +1,9 @@ :PROPERTIES: :ID: 6820973F-613E-441A-BC1D-8FE5CD9BD6F7 :END: -#+title: solid_principles +#+title: Solid Principles #+filetags: :career:notes:technical: +#+category: Career Concepts The SOLID principles are a set of five design principles that help software developers create maintainable, scalable, and flexible software systems. The principles were introduced by Robert C. Martin (Uncle Bob) and are widely used in object-oriented programming. @@ -19,3 +20,4 @@ The SOLID principles are: 5. **Dependency Inversion Principle (DIP)**: High-level modules should not depend on low-level modules; both should depend on abstractions. Additionally, abstractions should not depend on details; details should depend on abstractions. This principle encourages the use of interfaces and abstract classes to decouple high-level and low-level components. [[id:F3875F0F-5C9E-4BB1-A79C-6000B9558115][solid_principles_examples]] + diff --git a/20260101012731-solid_principles_examples.org b/Career Concepts/20260101012731-solid_principles_examples.org old mode 100755 new mode 100644 similarity index 100% rename from 20260101012731-solid_principles_examples.org rename to Career Concepts/20260101012731-solid_principles_examples.org diff --git a/20260115152626-apim.org b/Career Concepts/20260115152626-apim.org old mode 100755 new mode 100644 similarity index 100% rename from 20260115152626-apim.org rename to Career Concepts/20260115152626-apim.org diff --git a/Career Concepts/20260121173318-api_architecture.org b/Career Concepts/20260121173318-api_architecture.org new file mode 100644 index 0000000..0b0507d --- /dev/null +++ b/Career Concepts/20260121173318-api_architecture.org @@ -0,0 +1,544 @@ +:PROPERTIES: +:ID: 49b195c8-e116-40ca-86e8-62c65dbb5a4f +:END: +#+title: API Architecture +#+filetags: :notes:concepts:api: +#+category: Career Concepts + +*Z notes on API architecture - companion to [[id:56fabaf6-e8aa-45d0-a1c1-89f247f0a93f][APIM notes]]* + +* 1. What is API Architecture? + +API architecture is the set of rules, patterns, and structural decisions that govern how APIs are designed, exposed, consumed, and maintained across a system. It sits above individual API implementation - it's about *how APIs fit together* as a platform. + +In Microlise's context: the APIOps pipeline, the APIM gateway layer, OpenShift clusters, and the OpenAPI specs are all artefacts *of* an architectural decision. Understanding the architecture behind them makes the pipeline choices make sense. + +* 2. Architectural Styles + +Different styles define how clients and servers communicate. These are not mutually exclusive - a platform can expose multiple styles simultaneously (e.g. REST externally, gRPC internally). + +** 2.1 REST (Representational State Transfer) + +The dominant style for public and partner APIs. Key constraints: + +- *Stateless*: Each request must contain all the context needed to fulfil it. No session state is stored server-side between calls. +- *Resource-oriented*: APIs are modelled around nouns (resources), not verbs (actions). + - Good: ~GET /vehicles/{id}~ + - Bad: ~POST /getVehicle~ +- *Uniform interface*: Standard HTTP verbs carry semantic meaning: + | Verb | Meaning | + |--------+--------------------------------| + | GET | Read a resource | + | POST | Create a resource | + | PUT | Replace a resource entirely | + | PATCH | Partially update a resource | + | DELETE | Remove a resource | +- *Layered system*: Clients don't know if they're talking to the real backend or a gateway/proxy/cache. This is exactly what Microlise's APIM layer provides. +- *Cacheable*: Responses should declare whether they can be cached, enabling CDN and client-side optimisation. + +OpenAPI Specification (OAS/Swagger) is the standard way to *describe* a REST API. The ~spec~ referred to throughout the APIOps pipeline is this document. + +** 2.2 GraphQL + +A query language for APIs developed by Meta. Instead of fixed endpoints, clients send a query describing exactly what data they need. + +- Single endpoint: ~POST /graphql~ +- Client drives the shape of the response - no over-fetching or under-fetching. +- Good for: complex, interconnected data models; front-end teams who iterate quickly. +- Trade-off: harder to cache, more complex server-side resolver logic, linting/governance is less mature than OAS. + +Not currently the Microlise APIM pattern but worth understanding as a contrast. + +** 2.3 gRPC (Google Remote Procedure Call) + +Uses Protocol Buffers (protobuf) as the interface definition language and HTTP/2 as transport. + +- Strongly typed contracts defined in ~.proto~ files. +- Extremely high performance - binary serialisation, multiplexed streams. +- Ideal for: internal service-to-service calls, microservices, high-throughput scenarios. +- Trade-off: not human-readable, harder to test with standard tooling (curl, Postman), less browser-friendly. + +Think of gRPC as what might live *behind* an API gateway - internal communication between microservices - while REST/OAS faces outward toward customers. + +** 2.4 AsyncAPI / Event-Driven APIs + +Not all APIs are request-response. Event-driven APIs use messaging patterns: + +- *Webhooks*: Server POSTs to a client-registered URL when an event occurs. +- *WebSockets*: Persistent bi-directional connection between client and server. +- *Server-Sent Events (SSE)*: One-way stream from server to client. +- *Message queues* (Kafka, RabbitMQ, Azure Service Bus): Decoupled async messaging. + +AsyncAPI is the OAS equivalent for event-driven interfaces - a specification format for documenting these contracts. + +* 3. API Gateway Pattern + +This is the core of what APIM implements. An API gateway sits as an intermediary between consumers (customers, internal teams) and backend services. + +#+begin_src mermaid +flowchart TD + EC[External Consumer] + GW["API Gateway / APIM + ──────────────────── + Auth · Rate Limiting + Transforms · Routing + Logging · Caching"] + SA["Service A\n(OpenShift)"] + SB["Service B\n(OpenShift)"] + SC["Service C\n(OpenShift)"] + + EC --> GW + GW --> SA + GW --> SB + GW --> SC +#+end_src + +** 3.1 What the gateway does + +| Concern | What it means | +|--------------------------+-------------------------------------------------------------------------------| +| *Authentication* | Verifies who the caller is (OAuth2 tokens, API keys, mutual TLS) | +| *Authorisation* | Determines what the caller is allowed to do (scopes, claims) | +| *Rate limiting* | Caps requests per second/minute/hour per consumer or globally | +| *Throttling* | Gracefully slows or queues excess requests rather than rejecting them | +| *Request transformation* | Rewrites headers, payloads, or paths before forwarding to backends | +| *Response transformation*| Strips internal fields, reformats responses for the consumer contract | +| *Routing* | Directs traffic to the correct backend based on path, headers, or content | +| *Load balancing* | Distributes traffic across backend instances | +| *Caching* | Stores responses to reduce backend load for idempotent requests | +| *Observability* | Centralises access logs, metrics, and tracing across all APIs | + +In Azure APIM specifically, these concerns are implemented as *policies* - XML-based declarative rules that run at gateway level. + +** 3.2 Reverse Proxy vs API Gateway + +The Microlise notes reference a Reverse Proxy pipeline alongside APIM. These are related but distinct: + +| Aspect | Reverse Proxy | API Gateway | +|-------------------+-------------------------------------------+--------------------------------------------------| +| Primary purpose | Routing and TLS termination | Full API lifecycle management | +| Protocol awareness| Layer 4/7 (TCP/HTTP) | Layer 7, API-aware (understands REST, OAS) | +| Policy engine | Minimal (Nginx/HAProxy config) | Rich (auth, transforms, quotas, subscriptions) | +| Developer portal | No | Yes - consumer-facing API catalogue | +| Examples | Nginx, HAProxy, Traefik | Azure APIM, Kong, AWS API Gateway | + +A common pattern (and likely what Microlise uses) is: Reverse proxy handles ingress and TLS termination → traffic forwarded to APIM for policy enforcement → APIM routes to OpenShift services. + +* 4. API Design Principles + +** 4.1 Contract-First Design + +Define the OpenAPI spec *before* writing implementation code. The spec is the source of truth. + +Benefits: +- Frontend/consumer teams can mock and build against the spec immediately. +- Linting pipelines (like the one in APIOps gated build) can enforce governance before any code ships. +- Breaking change detection is automated. + +The APIOps pipeline enforces this: the spec is committed to source control, linted, reviewed by the API Governance Council, and only then does the publish pipeline sync it to APIM environments. + +** 4.2 Versioning Strategies + +APIs evolve. Versioning prevents changes from breaking existing consumers. + +| Strategy | Example | Trade-offs | +|---------------------+---------------------------------------+-----------------------------------------------------| +| *URI versioning* | ~/v1/vehicles~, ~/v2/vehicles~ | Explicit, cacheable, easy to route. Pollutes paths. | +| *Header versioning* | ~Accept: application/vnd.api.v2+json~ | Clean URIs. Harder to test, less cache-friendly. | +| *Query param* | ~/vehicles?version=2~ | Simple but considered poor practice for REST. | + +URI versioning is the most common and is what Azure APIM handles well via routing rules. + +** 4.3 Breaking vs Non-Breaking Changes + +Knowing what constitutes a breaking change is critical for API governance (i.e. why the API GC reviews spec PRs). + +| *Non-breaking (additive)* | *Breaking* | +|----------------------------------------+--------------------------------------------------| +| Adding a new optional field to response | Removing or renaming a field | +| Adding a new endpoint | Changing a field's type | +| Adding a new optional query parameter | Making an optional parameter required | +| New enum value (with caution) | Changing HTTP status codes for existing scenarios| +| | Changing authentication schemes | + +** 4.4 Resource Naming Conventions + +- Use *nouns*, not verbs: ~/journeys~ not ~/getJourneys~ +- Use *plural* for collections: ~/vehicles~ not ~/vehicle~ +- Use *kebab-case* for multi-word: ~/driver-events~ not ~/driverEvents~ +- Nest to show ownership, but limit depth: ~/vehicles/{id}/journeys~ is fine; ~/vehicles/{id}/journeys/{jid}/events/{eid}/metadata~ is not. +- Never expose internal implementation details in paths (~/{internalDatabaseId}~ leaks schema). + +** 4.5 HTTP Status Codes + +Correct status codes are part of the API contract. Misuse breaks consumers who rely on them. + +| Code | Meaning | When to use | +|------+-------------------------------+----------------------------------------------------| +| 200 | OK | Successful GET, PUT, PATCH | +| 201 | Created | Successful POST that created a resource | +| 204 | No Content | Successful DELETE or action with no response body | +| 400 | Bad Request | Client sent malformed/invalid data | +| 401 | Unauthorized | Not authenticated (no or invalid token) | +| 403 | Forbidden | Authenticated but not authorised for this resource | +| 404 | Not Found | Resource does not exist | +| 409 | Conflict | State conflict (duplicate, version mismatch) | +| 422 | Unprocessable Entity | Semantically invalid (e.g. invalid date range) | +| 429 | Too Many Requests | Rate limit exceeded | +| 500 | Internal Server Error | Unhandled server-side failure | +| 503 | Service Unavailable | Downstream dependency down, circuit breaker open | + +* 5. API Security Architecture + +** 5.1 Authentication Patterns + +| Pattern | How it works | Typical use | +|------------------+------------------------------------------------------------+------------------------------------------| +| *API Keys* | Static key passed in header (~x-api-key~) or query param | Simple, internal/partner APIs | +| *OAuth 2.0* | Token-based; client obtains a bearer token from auth server| Public APIs, delegated access | +| *OpenID Connect* | OAuth 2.0 + identity layer (ID tokens, user info endpoint) | APIs that need to know *who* the user is | +| *Mutual TLS* | Both client and server present certificates | High-security service-to-service | +| *JWT* | Signed token carrying claims; verified without calling auth server | Stateless auth at gateway level | + +Azure APIM supports all of these via policies. A common pattern: APIM validates the JWT at the gateway before the request ever reaches an OpenShift pod. + +** 5.2 OAuth 2.0 Grant Types + +| Grant type | Use case | +|-------------------------+----------------------------------------------------------------| +| *Client Credentials* | Machine-to-machine (no user involved). Most common for APIs. | +| *Authorization Code* | User-facing apps; user logs in and delegates access | +| *Authorization Code + PKCE* | Same as above but for SPAs/mobile (no client secret) | +| *Implicit* (deprecated) | Was used for SPAs - replaced by Auth Code + PKCE | + +** 5.3 Zero Trust at the API Layer + +Zero Trust means: *never trust, always verify* - even internal services must authenticate. + +Principles applied to APIs: +- Every service-to-service call requires a valid token (no implicit trust on the internal network). +- Tokens have minimum required scopes (principle of least privilege). +- mTLS between internal services adds a second layer even if a token is compromised. +- All traffic - internal and external - goes through the gateway and is logged. + +* 6. API Lifecycle Management + +This maps directly to the APIOps workflow in the APIM notes. + +#+begin_src mermaid +flowchart LR + Design[Design] + Develop[Develop] + Test[Test] + Publish[Publish] + Monitor[Monitor] + Retire[Retire] + + Design --> Develop --> Test --> Publish --> Monitor --> Retire + + Design -.-> D1["OAS Spec\nContract First"] + Develop -.-> D2["C# Project\nTemplates\nOpenShift"] + Test -.-> D3["Gated Build\nPipeline\nLinting + API GC"] + Publish -.-> D4["APIM Publish\nPipeline\nDev → Cert → Prod"] + Monitor -.-> D5["Analytics\nDashboards\nAPIM Portal"] + Retire -.-> D6["Deprecation\nNotices\nVersion Sunset"] +#+end_src + +** 6.1 API Governance + +The API Governance Council (API GC) referenced in the notes is the enforcement body for architectural standards. Common governance concerns: + +- *Linting*: Automated rules against the OAS spec. The APIOps pipeline uses scripts from ~ApiManagement.Pipeline.AgentScripts~ to enforce this. +- *Review gates*: No spec change merges without GC approval - prevents inconsistent or insecure APIs reaching production. +- *Naming standards*: Enforced in the spec review (see §4.4). +- *Breaking change policy*: Defines how long old versions must be supported before retirement. +- *Security policy*: All APIs must use approved auth methods; no unauthenticated endpoints in production. + +** 6.2 APIOps (GitOps for APIs) + +APIOps applies GitOps principles to API management: the APIM configuration is stored as code in a Git repository and the pipeline is the only mechanism that changes APIM state. + +Key properties: +- *Declarative*: The ~Microlise.APIOps~ repo describes the desired state of all APIs in APIM. +- *Versioned*: Every change is a PR - full audit trail. +- *Automated*: The publish pipeline does the two-way sync; no manual APIM portal edits. +- *Environment promotion*: Changes flow Dev -> Cert -> Prod, with a manual approval gate before Prod. + +This is analogous to how Terraform or Helm work for infrastructure - the repo *is* the truth. + +* 7. API Observability + +An often-overlooked architectural concern. APIs you can't observe are APIs you can't operate. + +** 7.1 The Three Pillars + +| Pillar | What it captures | Tooling examples | +|-----------+-------------------------------------------------------------+------------------------------------| +| *Logs* | Discrete events: requests, responses, errors, auth failures | Azure Monitor, ELK, Splunk | +| *Metrics* | Aggregated numbers over time: latency, error rate, RPS | Prometheus, Azure Metrics, Grafana | +| *Traces* | End-to-end request journey across services | Jaeger, Zipkin, Azure App Insights | + +** 7.2 Key API Metrics to Track + +- *Latency*: p50, p95, p99 - not just average. Averages hide outliers. +- *Error rate*: 5xx rate (server errors) and 4xx rate (client errors) separately. +- *Throughput*: Requests per second - used to set rate limits and plan capacity. +- *Availability*: Uptime percentage. SLAs are usually defined here (99.9% = ~8.7h downtime/year). +- *Quota consumption*: How much of a consumer's rate limit are they using? + +Azure APIM exposes all of these natively and can emit them to Azure Monitor. + +** 7.3 Correlation IDs + +Every request should carry a unique ~correlation-id~ (or ~x-request-id~) header. The gateway generates one if the client doesn't provide it and forwards it to all downstream services. This makes it possible to trace a single user request across multiple microservice logs. + +#+begin_src mermaid +flowchart LR + C[Client] + APIM["APIM\ngenerates correlation-id: abc-123"] + SA["Service A logs\nabc-123 · vehicle lookup"] + SB["Service B logs\nabc-123 · journey history"] + + C --> APIM + APIM --> SA + SA --> SB +#+end_src + +* 8. Microservices & API Design + +The OpenShift deployment model in Microlise's stack implies microservices. API architecture must account for how services communicate internally vs. externally. + +** 8.1 Internal vs External APIs + +| Aspect | Internal (East-West) | External (North-South) | +|----------------+--------------------------------------------+----------------------------------------------| +| Consumers | Other microservices | Customers, partners, third parties | +| Protocol | gRPC, internal REST, message queues | REST over HTTPS via APIM | +| Auth | mTLS, service accounts, internal tokens | OAuth2, API keys managed by APIM | +| Discoverability| Service mesh / internal DNS | Developer portal in APIM | +| Governance | Team-level conventions | API GC, formal versioning, SLA commitments | + +** 8.2 API Aggregation / BFF Pattern + +Backend for Frontend (BFF): a dedicated API layer tailored to a specific consumer (e.g. a mobile app, a portal). Instead of the consumer calling 5 microservices, a BFF aggregates them into a single call. + +#+begin_src mermaid +flowchart LR + MA[Mobile App] + BFF[BFF: Mobile API] + VS[Vehicle Service] + JS[Journey Service] + DS[Driver Service] + + MA --> BFF + BFF --> VS + BFF --> JS + BFF --> DS +#+end_src + +APIM policies can implement lightweight aggregation, but for complex cases a dedicated BFF service is cleaner. + +** 8.3 Service Mesh (Complementary to API Gateway) + +A service mesh (e.g. Istio, Linkerd) manages *internal* service-to-service communication within OpenShift/Kubernetes: + +- mTLS between pods automatically. +- Traffic policies (retries, circuit breaking) at the network level. +- Observability (traces, metrics) without code changes. + +The API Gateway handles North-South (external) traffic; the service mesh handles East-West (internal). They are complementary, not competing. + +* 9. API Design Patterns + +** 9.1 Pagination + +Never return unbounded collections. Standard patterns: + +- *Offset/limit*: ~GET /journeys?offset=0&limit=50~. Simple but inefficient at high offsets. +- *Cursor-based*: ~GET /journeys?cursor=eyJpZCI6MTAwfQ==~. Efficient for large datasets; the cursor encodes the last seen position. +- *Page-based*: ~GET /journeys?page=3&pageSize=50~. User-friendly but shares offset's inefficiency. + +Response should include metadata: +#+BEGIN_SRC json +{ + "data": [...], + "pagination": { + "total": 1420, + "limit": 50, + "nextCursor": "eyJpZCI6MTUwfQ==" + } +} +#+END_SRC + +** 9.2 Filtering, Sorting, and Field Selection + +- Filtering: ~GET /vehicles?status=active&driverType=HGV~ +- Sorting: ~GET /journeys?sort=-startedAt~ (prefix ~-~ for descending) +- Field selection (sparse fieldsets): ~GET /vehicles?fields=id,registration,status~ - reduces payload size. + +** 9.3 Idempotency + +A request is idempotent if making it multiple times produces the same result as making it once. Crucial for retry logic. + +| Method | Idempotent? | Safe (no side effects)? | +|--------+-------------+-------------------------| +| GET | Yes | Yes | +| PUT | Yes | No | +| DELETE | Yes | No | +| POST | No | No | +| PATCH | No* | No | + +*PATCH can be designed to be idempotent but isn't by definition. + +For non-idempotent operations (POST), use an ~Idempotency-Key~ header. The server stores the result keyed to that value; duplicate requests return the cached result rather than processing again. + +** 9.4 HATEOAS + +Hypermedia as the Engine of Application State - responses include links to related actions: + +#+BEGIN_SRC json +{ + "id": "v-123", + "registration": "AB12 CDE", + "_links": { + "self": { "href": "/vehicles/v-123" }, + "journeys": { "href": "/vehicles/v-123/journeys" }, + "driver": { "href": "/drivers/d-456" } + } +} +#+END_SRC + +Rarely implemented fully in practice but worth understanding as the most complete expression of REST. + +* 10. OpenAPI Specification Deep Dive + +Since OAS is central to the APIOps pipeline, understanding its structure is practical knowledge. + +#+BEGIN_SRC yaml +openapi: "3.1.0" +info: + title: Vehicle Service API + version: "2.0.0" + description: Manages vehicle records for the Microlise platform. + +servers: + - url: https://api.microlise.com/v2 + description: Production + +paths: + /vehicles/{vehicleId}: + get: + summary: Get a vehicle by ID + operationId: getVehicleById # Unique identifier used in code gen + tags: [Vehicles] + parameters: + - name: vehicleId + in: path + required: true + schema: + type: string + format: uuid + responses: + "200": + description: Vehicle found + content: + application/json: + schema: + $ref: "#/components/schemas/Vehicle" + "404": + $ref: "#/components/responses/NotFound" + +components: + schemas: + Vehicle: + type: object + required: [id, registration] + properties: + id: + type: string + format: uuid + registration: + type: string + example: "AB12 CDE" + status: + type: string + enum: [active, inactive, maintenance] + + responses: + NotFound: + description: Resource not found + content: + application/json: + schema: + $ref: "#/components/schemas/ProblemDetails" + + securitySchemes: + oauth2: + type: oauth2 + flows: + clientCredentials: + tokenUrl: https://auth.microlise.com/oauth2/token + scopes: + vehicles:read: Read vehicle data + vehicles:write: Create and update vehicles + +security: + - oauth2: [vehicles:read] +#+END_SRC + +Key OAS concepts: +- ~operationId~: Used by code generators and APIM to reference operations in policies. +- ~$ref~: DRY principle - define schemas and responses once, reuse everywhere. +- ~components~: The library section - schemas, parameters, responses, security schemes. +- ~tags~: Grouping for the developer portal - consumers see organised API docs. +- ~security~: Applied globally here; can be overridden per-operation. + +* 11. Connecting the Dots: Microlise Architecture Map + +Mapping the APIM notes to the architectural concepts above: + +| APIM Note Item | Architectural Concept | +|--------------------------------------------+-------------------------------------------------------| +| Separate layer between customers & APIs | API Gateway Pattern (§3) | +| OpenAPI spec / swagger build | Contract-First Design (§4.1), OAS (§10) | +| APIOps pipeline, spec in git | APIOps / GitOps for APIs (§6.2) | +| API Governance Council review | API Governance (§6.1), Breaking Changes (§4.3) | +| Linting scripts (~AgentScripts~) | Automated governance enforcement | +| Gated + main pipeline | CI/CD gates for quality and security | +| Two-way sync, publish pipeline | Declarative state management (APIOps) | +| Dev -> Cert -> Prod with approval gate | Environment promotion pattern (§6.2) | +| Gen cluster vs Prod cluster | Environment isolation, blast radius reduction | +| Reverse proxy pipeline | Reverse Proxy vs API Gateway (§3.2) | +| Quay registry, OpenShift containers | Microservices deployment, East-West traffic (§8.1) | +| Swagger/OAS spec as PR artefact | Spec-as-code, version-controlled contracts | + +* 12. Further Reading & Reference + +** Recommended (from APIM notes) + +- Quick Start Kubernetes - Nigel Poulton ([[https://microliseuk.sharepoint.com/sites/StorageCompute/ContainerPlatformUsers/SitePages/How-is-OpenShift-different-from-Kubernetes.aspx][OpenShift vs K8s]]) + +** Additional Architecture Resources + +- [[https://spec.openapis.org/oas/v3.1.0][OpenAPI Specification 3.1.0 (official)]] +- [[https://www.asyncapi.com/docs][AsyncAPI Documentation]] +- [[https://grpc.io/docs/][gRPC Official Docs]] +- [[https://learn.microsoft.com/en-us/azure/api-management/][Azure API Management Docs]] +- [[https://microservices.io/patterns/apigateway.html][Microservices.io - API Gateway Pattern]] +- [[https://oauth.net/2/][OAuth 2.0 (oauth.net)]] +- [[https://swagger.io/specification/][Swagger / OAS Reference]] + +** Key Terms Glossary + +| Term | Definition | +|----------------+------------------------------------------------------------------------------| +| OAS / Swagger | OpenAPI Specification - a standard format for describing REST APIs | +| APIOps | Applying GitOps principles to API management (spec-as-code, pipeline-driven) | +| APIM | API Management - the platform/layer that governs API lifecycle | +| Gateway | Intermediary that enforces policy (auth, rate limiting, routing) for APIs | +| Spec | Short for specification - the OAS JSON/YAML document describing an API | +| Idempotency | Property where repeating a request has the same effect as making it once | +| mTLS | Mutual TLS - both parties in a connection authenticate with certificates | +| BFF | Backend for Frontend - an API tailored to a specific consumer's needs | +| Service Mesh | Infrastructure layer managing internal service-to-service communication | +| Breaking Change| An API change that requires existing consumers to update their integration | diff --git a/20260305102210-cicd_example.org b/Career Concepts/20260305102210-cicd_example.org similarity index 99% rename from 20260305102210-cicd_example.org rename to Career Concepts/20260305102210-cicd_example.org index 29df4e2..8031fa9 100644 --- a/20260305102210-cicd_example.org +++ b/Career Concepts/20260305102210-cicd_example.org @@ -2,6 +2,7 @@ :ID: 2767b5ac-f2c9-4b1e-ab87-82c43cdec4c1 :END: #+title: CI/CD Example +#+category: Career Concepts During the first wave in 2026, we planned to get the netcore version of site visits out to customers. There were a bunch of tasks relating to this, so I asked AI to conceptually explain them. diff --git a/20260305111610-cicd_summary.org b/Career Concepts/20260305111610-cicd_summary.org similarity index 98% rename from 20260305111610-cicd_summary.org rename to Career Concepts/20260305111610-cicd_summary.org index ef4b1f1..add0015 100644 --- a/20260305111610-cicd_summary.org +++ b/Career Concepts/20260305111610-cicd_summary.org @@ -2,6 +2,7 @@ :ID: 5b714c6c-7eaf-4f3f-b4f6-2166ff3a9963 :END: #+title: CI/CD Summary +#+category: Career Concepts * Summary CI/CD stands for Continuous Integration and Continuous Delivery/Deployment. It’s a development practice that automates building, testing, and delivering software so code changes can be released quickly and reliably. diff --git a/20260305130457-database_perms_roles_accounts.org b/Career Concepts/20260305130457-database_perms_roles_accounts.org similarity index 99% rename from 20260305130457-database_perms_roles_accounts.org rename to Career Concepts/20260305130457-database_perms_roles_accounts.org index 9571041..f49b845 100644 --- a/20260305130457-database_perms_roles_accounts.org +++ b/Career Concepts/20260305130457-database_perms_roles_accounts.org @@ -2,6 +2,7 @@ :ID: b4858f6a-b05c-47f2-972e-905e0bb2c352 :END: #+title: Database Permissions, Roles, and Accounts +#+category: Career Concepts * Introduction Database security is a crucial part of database administration. It ensures that only authorised users can access, modify, or manage data. Three core concepts used to control access are: diff --git a/20260305132058-restful_api.org b/Career Concepts/20260305132058-restful_api.org similarity index 99% rename from 20260305132058-restful_api.org rename to Career Concepts/20260305132058-restful_api.org index bb8bac4..a05992a 100644 --- a/20260305132058-restful_api.org +++ b/Career Concepts/20260305132058-restful_api.org @@ -2,6 +2,7 @@ :ID: 6a5bf6dd-d0ec-43e4-8e07-9956f4715f10 :END: #+title: RESTful APIs +#+category: Career Concepts * What is a RESTful API? diff --git a/20241210004247-emacs_moc.org b/Emacs/20241210004247-emacs_moc.org old mode 100755 new mode 100644 similarity index 68% rename from 20241210004247-emacs_moc.org rename to Emacs/20241210004247-emacs_moc.org index 2d03126..c2306df --- a/20241210004247-emacs_moc.org +++ b/Emacs/20241210004247-emacs_moc.org @@ -2,23 +2,19 @@ :ID: 8fa3f476-6152-45f4-b618-50f1e4bce46c :END: #+title: Emacs MOC -#+filetags: :resources:index:docs:emacs: +#+filetags: :emacs:moc: The purpose of this file is to store things related to emacs (that being packages, or community projects that i stumble across). +* Links +- [[id:034abe27-ca14-4dc0-9a3f-b8d0e1f26342][Emacs Org Roam]] for roam related things +- [[id:8e5e9498-ff3c-48e7-aab5-6e94b2e41ccb][Emacs GTD]] +- [[id:966175d4-3b58-4abc-9b41-08cbf328dd87][Emacs Keybindings]] +- [[id:7e79e4c5-383d-450f-882c-33d4f87ba1b5][Emacs ELISP]] +- [[id:2ab0fa3f-8ac6-4af2-8cd4-1dd490fb19c3][Emacs Magit]] +- [[id:45CC3AF5-5E20-4B03-A36C-8D4BDD5CBB13][Emacs Evil Mode]] +- [[id:7d2e867e-f091-4362-a583-453f732207fe][Emacs ORG Publish]] -- [[id:034abe27-ca14-4dc0-9a3f-b8d0e1f26342][emacs-stuff-org-roam]] for roam related things - -- [[id:8e5e9498-ff3c-48e7-aab5-6e94b2e41ccb][emacs-stuff-gtd]] - -- [[id:966175d4-3b58-4abc-9b41-08cbf328dd87][emacs-stuff-keybindings]] - -- [[id:7e79e4c5-383d-450f-882c-33d4f87ba1b5][emacs-stuff-elisp]] - -- [[id:2ab0fa3f-8ac6-4af2-8cd4-1dd490fb19c3][emacs-stuff-magit]] - -- [[id:45CC3AF5-5E20-4B03-A36C-8D4BDD5CBB13][emacs-stuff-evil]] - - +* Resources - A link that contains all the key bindings for emacs: [[http://xahlee.info/emacs/emacs/emacs_keybinding_list.html][Keybindings list]] - the theme 'ef-dream' repository: [[https://github.com/protesilaos/ef-themes][ef-themes]] - something to look into: [[https://github.com/mickeynp/combobulate][combobulate]] @@ -30,3 +26,13 @@ The purpose of this file is to store things related to emacs (that being package - the theme im currently using: [[https://github.com/ogdenwebb/emacs-kaolin-themes?tab=readme-ov-file][kaolin]] - config: [[https://gitlab.com/dwt1/configuring-emacs][config-dwt]] - simplenote to self hosted: [[https://ru2saig.github.io/posts/switching-from-simplenote-to-a-self-hosted-approach-nextcloud-orgzly-and-emacs/][Link]] + + + +[[../assets/file_example_MOV_480_700kB.mov]] + + +[[../assets/file_example_MP4_480_1_5MG.mp4]] + + +[[../assets/file_example_MP3_700KB.mp3]] diff --git a/20241210004329-org_roam.org b/Emacs/20241210004329-org_roam.org old mode 100755 new mode 100644 similarity index 91% rename from 20241210004329-org_roam.org rename to Emacs/20241210004329-org_roam.org index 979e05c..6f16d89 --- a/20241210004329-org_roam.org +++ b/Emacs/20241210004329-org_roam.org @@ -3,7 +3,7 @@ :END: #+title: Emacs Org Roam #+filetags: :emacs:roam:org:docs:resources: -This base will contain information on org roam. Although its closely linked to the [[id:8e5e9498-ff3c-48e7-aab5-6e94b2e41ccb][emacs-stuff-gtd]] node, that one will contain articles, notes and videos related to how to get things done. +This base will contain information on org roam. Although its closely linked to the [[id:8e5e9498-ff3c-48e7-aab5-6e94b2e41ccb][Emacs GTD]] node, that one will contain articles, notes and videos related to how to get things done. * Main [[https://www.orgroam.com/manual.html][User Manual]] diff --git a/20241210004453-gtd.org b/Emacs/20241210004453-gtd.org old mode 100755 new mode 100644 similarity index 100% rename from 20241210004453-gtd.org rename to Emacs/20241210004453-gtd.org diff --git a/20250218174735-emacs_stuff_keybindings.org b/Emacs/20250218174735-emacs_stuff_keybindings.org old mode 100755 new mode 100644 similarity index 91% rename from 20250218174735-emacs_stuff_keybindings.org rename to Emacs/20250218174735-emacs_stuff_keybindings.org index 6510ae5..f51746b --- a/20250218174735-emacs_stuff_keybindings.org +++ b/Emacs/20250218174735-emacs_stuff_keybindings.org @@ -1,7 +1,7 @@ :PROPERTIES: :ID: 966175d4-3b58-4abc-9b41-08cbf328dd87 :END: -#+title: emacs-stuff-keybindings +#+title: Emacs Keybindings #+filetags: :emacs:guide: Keybindings I have come across: diff --git a/20250326002128-emacs_stuff_elisp.org b/Emacs/20250326002128-emacs_stuff_elisp.org old mode 100755 new mode 100644 similarity index 98% rename from 20250326002128-emacs_stuff_elisp.org rename to Emacs/20250326002128-emacs_stuff_elisp.org index 0c6bfed..257ed82 --- a/20250326002128-emacs_stuff_elisp.org +++ b/Emacs/20250326002128-emacs_stuff_elisp.org @@ -1,7 +1,7 @@ :PROPERTIES: :ID: 7e79e4c5-383d-450f-882c-33d4f87ba1b5 :END: -#+title: emacs-stuff-elisp +#+title: Emacs ELISP #+filetags: :emacs:elisp:guide: -- use ` fixes: + +Up To Date Fixes: +We need to add zaine to the www-data group: + +#+begin_src bash + sudo usermod -aG www-data zaine +#+end_src + +Then we need to make the directories setgid, so that any new files created will have the group www-data: + +#+begin_src bash + sudo chown -R zaine:www-data /home/zaine/master-folder + sudo chmod -R 2775 /home/zaine/master-folder # the 2 sets the setgid bit, which means that new files will inherit the group of the directory, which is www-data +#+end_src + +*** Older fixes +So apparently, nextcloud needs to have www-data as the owner of the files, and to do that, we need to run the following command: + +#+begin_src bash +sudo chown -R www-data:www-data /home/zaine/master-folder +#+end_src + +I modified the build scripts to change permissions back to zaine:zaine when deleting the output folder, then changing it back to www-data:www-data. + +One other useful thing may be: + +#+begin_src bash + + docker exec -u 1000:1000 -it nextcloud-app-1 php occ files:scan --all + + # or + + docker exec -u 1000 nextcloud-app-1 php occ files:scan --path="zaine/files/master-folder" + +#+end_src + +One other thing: + +#+begin_src bash + i FIXED IT BY doing this: + + zaine@zaine-HP-ProDesk-400-G1-SFF [09:47:47] [~/docker-services/nextcloud] + -> % docker exec -it postgres psql -U nextcloud -d nextcloud + psql (17.5 (Debian 17.5-1.pgdg120+1)) + Type "help" for help. + + nextcloud=> SELECT * FROM oc_file_locks; + nextcloud=> DELETE FROM oc_file_locks; + DELETE 15002 + nextcloud=> \q + zaine@zaine-HP-ProDesk-400-G1-SFF [09:49:01] [~/docker-services/nextcloud] + -> % docker exec -it nextcloud-app-1 ls /mnt/master-folder + alimiyyah attachments booking career hurra.txt org_files pdfs projects uni + zaine@zaine-HP-ProDesk-400-G1-SFF [09:49:04] [~/docker-services/nextcloud] + -> % docker exec -u 1000 -it nextcloud-app-1 php occ files:scan --all + Starting scan for user 1 out of 2 (halima) + Starting scan for user 2 out of 2 (zaine) + +---------+-------+-----+---------+---------+--------+--------------+ + | Folders | Files | New | Updated | Removed | Errors | Elapsed time | + +---------+-------+-----+---------+---------+--------+--------------+ + | 1985 | 12906 | 0 | 522 | 0 | 0 | 00:00:50 | + +---------+-------+-----+---------+---------+--------+--------------+ + zaine@zaine-HP-ProDesk-400-G1-SFF [09:49:59] [~/docker-services/nextcloud] + -> % + + there is some issue in the nextcloud permissions itself. if i create a file and delete it in windows, i get this error in the client: A + master-folder/hehe.txt + now + The resource you are trying to access is currently locked and cannot be modified. Please try changing it later, or contact your server administrator ... + + and if i try to delete it in nextcloud ui (web), it says file cant be deleted + +#+end_src + + + * Config Location is: diff --git a/20251019114736-server_moc.org b/Linux/20251019114736-server_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20251019114736-server_moc.org rename to Linux/20251019114736-server_moc.org diff --git a/20260104155940-server_backend.org b/Linux/20260104155940-server_backend.org old mode 100755 new mode 100644 similarity index 100% rename from 20260104155940-server_backend.org rename to Linux/20260104155940-server_backend.org diff --git a/20260227103506-vaultwarden.org b/Linux/20260227103506-vaultwarden.org similarity index 100% rename from 20260227103506-vaultwarden.org rename to Linux/20260227103506-vaultwarden.org diff --git a/Makefile b/Makefile old mode 100755 new mode 100644 index 41e0be4..a7ca4b8 --- a/Makefile +++ b/Makefile @@ -1,7 +1,6 @@ -.PHONY: all build json fast clean norm tests help +.PHONY: all build json json-2 fast clean norm tests fix-permissions help -# Default target: full build with search index -all: clean json build +all: clean json build json-2 build: @echo "Building project (full rebuild with search index)..." @@ -11,12 +10,14 @@ json: @echo "Generating the JSON output..." /usr/bin/python3 search-index.py -# Fast build without search index +json-2: + @echo "Generating the JSON output 2..." + /usr/bin/python3 generate_sidebar_tree.py + fast: @echo "Building project (fast rebuild without search index)..." emacs -Q --script lisp/build.el --fast -# Clean output directory clean: @echo "Cleaning output directory..." rm -rf output/ @@ -29,7 +30,12 @@ tests: @echo "Running all the tests..." emacs -batch -l ert -l tests/macros-tests.el -f ert-run-tests-batch-and-exit -# Show help message +fix-permissions: + echo "shakkal123" | sudo -S chown -R zaine:zaine . + +restore-permissions: + echo "shakkal123" | sudo -S chown -R 33:33 . + help: @echo "Available targets:" @echo " make - Clean, build, and generate search index (default)" @@ -39,4 +45,6 @@ help: @echo " make clean - Remove output directory" @echo " make tests - Run all of the tests associated with the project" @echo " make norm - Move all files that end with ~ to the backup folder" + @echo " make fix-permissions - Fix permissions for the project directory (requires sudo)" + @echo " make restore-permissions - Restore permissions for the project directory (requires sudo)" @echo " make help - Show this help message" diff --git a/20241210001045-technical_moc.org b/Misc/20241210001045-technical_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20241210001045-technical_moc.org rename to Misc/20241210001045-technical_moc.org diff --git a/20241211161232- job_application_cover_letters.org b/Misc/20241211161232- job_application_cover_letters.org old mode 100755 new mode 100644 similarity index 100% rename from 20241211161232- job_application_cover_letters.org rename to Misc/20241211161232- job_application_cover_letters.org diff --git a/20241211161232-applications.org b/Misc/20241211161232-applications.org old mode 100755 new mode 100644 similarity index 100% rename from 20241211161232-applications.org rename to Misc/20241211161232-applications.org diff --git a/20250402185735-java_moc.org b/Misc/20250402185735-java_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250402185735-java_moc.org rename to Misc/20250402185735-java_moc.org diff --git a/20250430001952-microlise_assessment.org b/Misc/20250430001952-microlise_assessment.org old mode 100755 new mode 100644 similarity index 100% rename from 20250430001952-microlise_assessment.org rename to Misc/20250430001952-microlise_assessment.org diff --git a/20250717230336-recipes_moc.org b/Misc/20250717230336-recipes_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250717230336-recipes_moc.org rename to Misc/20250717230336-recipes_moc.org diff --git a/20250719174944-recipes_ideas.org b/Misc/20250719174944-recipes_ideas.org old mode 100755 new mode 100644 similarity index 100% rename from 20250719174944-recipes_ideas.org rename to Misc/20250719174944-recipes_ideas.org diff --git a/20250719175023-recipes_done.org b/Misc/20250719175023-recipes_done.org old mode 100755 new mode 100644 similarity index 100% rename from 20250719175023-recipes_done.org rename to Misc/20250719175023-recipes_done.org diff --git a/20250723185829-test_driven_development.org b/Misc/20250723185829-test_driven_development.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723185829-test_driven_development.org rename to Misc/20250723185829-test_driven_development.org diff --git a/20250723185943-bowling_kata.org b/Misc/20250723185943-bowling_kata.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723185943-bowling_kata.org rename to Misc/20250723185943-bowling_kata.org diff --git a/20250723190203-java_portswrigger_test.org b/Misc/20250723190203-java_portswrigger_test.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723190203-java_portswrigger_test.org rename to Misc/20250723190203-java_portswrigger_test.org diff --git a/20250723190656-java_junit_testing.org b/Misc/20250723190656-java_junit_testing.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723190656-java_junit_testing.org rename to Misc/20250723190656-java_junit_testing.org diff --git a/20250806111925-non_technical_moc.org b/Misc/20250806111925-non_technical_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250806111925-non_technical_moc.org rename to Misc/20250806111925-non_technical_moc.org diff --git a/20250918120519-misc_moc.org b/Misc/20250918120519-misc_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250918120519-misc_moc.org rename to Misc/20250918120519-misc_moc.org diff --git a/20250918120706-wedding_moc.org b/Misc/20250918120706-wedding_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250918120706-wedding_moc.org rename to Misc/20250918120706-wedding_moc.org diff --git a/20250926151524-workflow_moc.org b/Misc/20250926151524-workflow_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250926151524-workflow_moc.org rename to Misc/20250926151524-workflow_moc.org diff --git a/20251002154125-microlise_moc.org b/Misc/20251002154125-microlise_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20251002154125-microlise_moc.org rename to Misc/20251002154125-microlise_moc.org diff --git a/20251002154204-pre_work_prep_microlise.org b/Misc/20251002154204-pre_work_prep_microlise.org old mode 100755 new mode 100644 similarity index 100% rename from 20251002154204-pre_work_prep_microlise.org rename to Misc/20251002154204-pre_work_prep_microlise.org diff --git a/20251019114758-old_nextcloud_server_code.org b/Misc/20251019114758-old_nextcloud_server_code.org old mode 100755 new mode 100644 similarity index 100% rename from 20251019114758-old_nextcloud_server_code.org rename to Misc/20251019114758-old_nextcloud_server_code.org diff --git a/20251101123637-backlog.org b/Misc/20251101123637-backlog.org old mode 100755 new mode 100644 similarity index 100% rename from 20251101123637-backlog.org rename to Misc/20251101123637-backlog.org diff --git a/20251109205925-old_nginx_code.org b/Misc/20251109205925-old_nginx_code.org old mode 100755 new mode 100644 similarity index 100% rename from 20251109205925-old_nginx_code.org rename to Misc/20251109205925-old_nginx_code.org diff --git a/20251122223053-keyboard.org b/Misc/20251122223053-keyboard.org old mode 100755 new mode 100644 similarity index 100% rename from 20251122223053-keyboard.org rename to Misc/20251122223053-keyboard.org diff --git a/20251214210526-useful_c_imports.org b/Misc/20251214210526-useful_c_imports.org old mode 100755 new mode 100644 similarity index 100% rename from 20251214210526-useful_c_imports.org rename to Misc/20251214210526-useful_c_imports.org diff --git a/20251223220531-technical_commonplace.org b/Misc/20251223220531-technical_commonplace.org old mode 100755 new mode 100644 similarity index 100% rename from 20251223220531-technical_commonplace.org rename to Misc/20251223220531-technical_commonplace.org diff --git a/20260101143401-actual_self_hosted.org b/Misc/20260101143401-actual_self_hosted.org old mode 100755 new mode 100644 similarity index 100% rename from 20260101143401-actual_self_hosted.org rename to Misc/20260101143401-actual_self_hosted.org diff --git a/20260101194248-gitea.org b/Misc/20260101194248-gitea.org old mode 100755 new mode 100644 similarity index 100% rename from 20260101194248-gitea.org rename to Misc/20260101194248-gitea.org diff --git a/20260107182221-2026_targets.org b/Misc/20260107182221-2026_targets.org old mode 100755 new mode 100644 similarity index 100% rename from 20260107182221-2026_targets.org rename to Misc/20260107182221-2026_targets.org diff --git a/20260111204228-rss_articles.org b/Misc/20260111204228-rss_articles.org old mode 100755 new mode 100644 similarity index 100% rename from 20260111204228-rss_articles.org rename to Misc/20260111204228-rss_articles.org diff --git a/20260117194854-programming_projects.org b/Misc/20260117194854-programming_projects.org old mode 100755 new mode 100644 similarity index 100% rename from 20260117194854-programming_projects.org rename to Misc/20260117194854-programming_projects.org diff --git a/20260211114817-personal_operating_system.org b/Misc/20260211114817-personal_operating_system.org old mode 100755 new mode 100644 similarity index 100% rename from 20260211114817-personal_operating_system.org rename to Misc/20260211114817-personal_operating_system.org diff --git a/20260211124505-timetable.org b/Misc/20260211124505-timetable.org old mode 100755 new mode 100644 similarity index 100% rename from 20260211124505-timetable.org rename to Misc/20260211124505-timetable.org diff --git a/20260307165727-proverbs.org b/Misc/20260307165727-proverbs.org similarity index 100% rename from 20260307165727-proverbs.org rename to Misc/20260307165727-proverbs.org diff --git a/20260307233451-recipes_cookbook.org b/Misc/20260307233451-recipes_cookbook.org similarity index 98% rename from 20260307233451-recipes_cookbook.org rename to Misc/20260307233451-recipes_cookbook.org index 944493c..8c3b427 100644 --- a/20260307233451-recipes_cookbook.org +++ b/Misc/20260307233451-recipes_cookbook.org @@ -6,7 +6,7 @@ #+AUTHOR: Auto-generated #+filetags: :recipes:cooking:org:index: #+STARTUP: content -#+PROPERTY: GENERATED_AT 2026-03-21T00:00:04.075739 +#+PROPERTY: GENERATED_AT 2026-03-27T00:00:02.222838 # How to add notes: under any recipe heading, add :COOKED: to record when you made it, and :TIPS: your tip text to add notes. # Multiple :COOKED: lines are supported. These are preserved across regenerations. diff --git a/20241210001150-aoc_notes.org b/Notes/20241210001150-aoc_notes.org old mode 100755 new mode 100644 similarity index 100% rename from 20241210001150-aoc_notes.org rename to Notes/20241210001150-aoc_notes.org diff --git a/20241210001206-leetcode_notes.org b/Notes/20241210001206-leetcode_notes.org old mode 100755 new mode 100644 similarity index 100% rename from 20241210001206-leetcode_notes.org rename to Notes/20241210001206-leetcode_notes.org diff --git a/20241212013207-haskell_notes.org b/Notes/20241212013207-haskell_notes.org old mode 100755 new mode 100644 similarity index 100% rename from 20241212013207-haskell_notes.org rename to Notes/20241212013207-haskell_notes.org diff --git a/20241212013902-lazy_evaluation.org b/Notes/20241212013902-lazy_evaluation.org old mode 100755 new mode 100644 similarity index 100% rename from 20241212013902-lazy_evaluation.org rename to Notes/20241212013902-lazy_evaluation.org diff --git a/20241213005125-c_notes.org b/Notes/20241213005125-c_notes.org old mode 100755 new mode 100644 similarity index 100% rename from 20241213005125-c_notes.org rename to Notes/20241213005125-c_notes.org diff --git a/20241213005156-socket_programming_in_c.org b/Notes/20241213005156-socket_programming_in_c.org old mode 100755 new mode 100644 similarity index 100% rename from 20241213005156-socket_programming_in_c.org rename to Notes/20241213005156-socket_programming_in_c.org diff --git a/20241217234535-web_port_notes.org b/Notes/20241217234535-web_port_notes.org old mode 100755 new mode 100644 similarity index 100% rename from 20241217234535-web_port_notes.org rename to Notes/20241217234535-web_port_notes.org diff --git a/20241217234944-wp_emacs_config_blorg.org b/Notes/20241217234944-wp_emacs_config_blorg.org old mode 100755 new mode 100644 similarity index 100% rename from 20241217234944-wp_emacs_config_blorg.org rename to Notes/20241217234944-wp_emacs_config_blorg.org diff --git a/20241220234456-github_notes.org b/Notes/20241220234456-github_notes.org old mode 100755 new mode 100644 similarity index 100% rename from 20241220234456-github_notes.org rename to Notes/20241220234456-github_notes.org diff --git a/20250111213016-wp_prefront_cortex_blog.org b/Notes/20250111213016-wp_prefront_cortex_blog.org old mode 100755 new mode 100644 similarity index 100% rename from 20250111213016-wp_prefront_cortex_blog.org rename to Notes/20250111213016-wp_prefront_cortex_blog.org diff --git a/20250214155617-wp_new_emacs_config_blorg.org b/Notes/20250214155617-wp_new_emacs_config_blorg.org old mode 100755 new mode 100644 similarity index 100% rename from 20250214155617-wp_new_emacs_config_blorg.org rename to Notes/20250214155617-wp_new_emacs_config_blorg.org diff --git a/20250226184629-wp_urge_surfing_blorg.org b/Notes/20250226184629-wp_urge_surfing_blorg.org old mode 100755 new mode 100644 similarity index 100% rename from 20250226184629-wp_urge_surfing_blorg.org rename to Notes/20250226184629-wp_urge_surfing_blorg.org diff --git a/20250314223811-wp_growth_mindset.org b/Notes/20250314223811-wp_growth_mindset.org old mode 100755 new mode 100644 similarity index 100% rename from 20250314223811-wp_growth_mindset.org rename to Notes/20250314223811-wp_growth_mindset.org diff --git a/20250314230952-wp_emotional_intelligence.org b/Notes/20250314230952-wp_emotional_intelligence.org old mode 100755 new mode 100644 similarity index 100% rename from 20250314230952-wp_emotional_intelligence.org rename to Notes/20250314230952-wp_emotional_intelligence.org diff --git a/20250324041724-wp_week_12_reflections.org b/Notes/20250324041724-wp_week_12_reflections.org old mode 100755 new mode 100644 similarity index 100% rename from 20250324041724-wp_week_12_reflections.org rename to Notes/20250324041724-wp_week_12_reflections.org diff --git a/20250402185735-technical_java_notes.org b/Notes/20250402185735-technical_java_notes.org old mode 100755 new mode 100644 similarity index 100% rename from 20250402185735-technical_java_notes.org rename to Notes/20250402185735-technical_java_notes.org diff --git a/20250412234351-wp_sadness.org b/Notes/20250412234351-wp_sadness.org old mode 100755 new mode 100644 similarity index 100% rename from 20250412234351-wp_sadness.org rename to Notes/20250412234351-wp_sadness.org diff --git a/20250723171109-maven_pom_file.org b/Notes/20250723171109-maven_pom_file.org old mode 100755 new mode 100644 similarity index 100% rename from 20250723171109-maven_pom_file.org rename to Notes/20250723171109-maven_pom_file.org diff --git a/20250727121051-networking_moc.org b/Notes/20250727121051-networking_moc.org old mode 100755 new mode 100644 similarity index 100% rename from 20250727121051-networking_moc.org rename to Notes/20250727121051-networking_moc.org diff --git a/20250804212215-how_to_solve_leetcode.org b/Notes/20250804212215-how_to_solve_leetcode.org old mode 100755 new mode 100644 similarity index 100% rename from 20250804212215-how_to_solve_leetcode.org rename to Notes/20250804212215-how_to_solve_leetcode.org diff --git a/20250804212606-leetcode_arrays.org b/Notes/20250804212606-leetcode_arrays.org old mode 100755 new mode 100644 similarity index 100% rename from 20250804212606-leetcode_arrays.org rename to Notes/20250804212606-leetcode_arrays.org diff --git a/20250804214537-python_set.org b/Notes/20250804214537-python_set.org old mode 100755 new mode 100644 similarity index 100% rename from 20250804214537-python_set.org rename to Notes/20250804214537-python_set.org diff --git a/20250805141906-python_dictionary.org b/Notes/20250805141906-python_dictionary.org old mode 100755 new mode 100644 similarity index 100% rename from 20250805141906-python_dictionary.org rename to Notes/20250805141906-python_dictionary.org diff --git a/20250805143427-python_sorted_function.org b/Notes/20250805143427-python_sorted_function.org old mode 100755 new mode 100644 similarity index 100% rename from 20250805143427-python_sorted_function.org rename to Notes/20250805143427-python_sorted_function.org diff --git a/20250805143741-python_lambda.org b/Notes/20250805143741-python_lambda.org old mode 100755 new mode 100644 similarity index 100% rename from 20250805143741-python_lambda.org rename to Notes/20250805143741-python_lambda.org diff --git a/20241210012703-fyp.org b/Uni/20241210012703-fyp.org old mode 100755 new mode 100644 similarity index 100% rename from 20241210012703-fyp.org rename to Uni/20241210012703-fyp.org diff --git a/20241210152650-uni_moc.org b/Uni/20241210152650-uni_moc.org old mode 100755 new mode 100644 similarity index 84% rename from 20241210152650-uni_moc.org rename to Uni/20241210152650-uni_moc.org index 547a9f2..66a1e3e --- a/20241210152650-uni_moc.org +++ b/Uni/20241210152650-uni_moc.org @@ -7,6 +7,6 @@ - [[id:5443ed1c-bb7f-4eb4-9c96-d12648dd2291][TPIS]] - [[id:556d10d1-1c74-4d9f-a398-39cb3bd5d935][AFP]] - [[id:c69e4c4d-2fb4-4cf1-a835-a235cf6db8e9][ISE]] -- [[id:3acffb66-bc1a-4661-904f-c5447b3c3488][advanced-networking]] +- [[id:3acffb66-bc1a-4661-904f-c5447b3c3488][Advanced Networking]] * Final Year Project - [[id:7d199fbe-b0e7-48fd-b8a1-793044dbea01][FYP]] Final Year Project diff --git a/20241210152713-tpis.org b/Uni/20241210152713-tpis.org old mode 100755 new mode 100644 similarity index 100% rename from 20241210152713-tpis.org rename to Uni/20241210152713-tpis.org diff --git a/20241210232054-uml_fyp.org b/Uni/20241210232054-uml_fyp.org old mode 100755 new mode 100644 similarity index 100% rename from 20241210232054-uml_fyp.org rename to Uni/20241210232054-uml_fyp.org diff --git a/Uni/20250120110833-afp.org b/Uni/20250120110833-afp.org new file mode 100644 index 0000000..467d13f --- /dev/null +++ b/Uni/20250120110833-afp.org @@ -0,0 +1,11 @@ +:PROPERTIES: +:ID: 556d10d1-1c74-4d9f-a398-39cb3bd5d935 +:END: +#+title: AFP (Advanced Functional Programming) +#+filetags: :uni:index: + +- [[id:6c272430-aff5-468b-90d3-5ff3a96152cf][AFP Week 1]] + +- [[id:4bc71106-1d2b-4c71-836d-54b738fe5ff5][AFP Week 2]] + +- [[id:1f395b8c-cf55-43eb-9430-dd9449f6b575][AFP Week 3]] diff --git a/20250120111047-afp_week1.org b/Uni/20250120111047-afp_week1.org old mode 100755 new mode 100644 similarity index 83% rename from 20250120111047-afp_week1.org rename to Uni/20250120111047-afp_week1.org index ef72d68..605cd8a --- a/20250120111047-afp_week1.org +++ b/Uni/20250120111047-afp_week1.org @@ -1,10 +1,10 @@ :PROPERTIES: :ID: 6c272430-aff5-468b-90d3-5ff3a96152cf :END: -#+title: afp_week1 +#+title: AFP Week 1 #+filetags: :uni:index: -* <2025-01-20 Mon> : [[id:f6c9e1a7-8465-4cef-9481-2b803d0c43d4][afp_lab_1]] +* <2025-01-20 Mon> : [[id:f6c9e1a7-8465-4cef-9481-2b803d0c43d4][AFP Lab 1]] - Installing Agda -* <2025-01-21 Tue> : [[id:3aef24fd-b220-4408-aa1e-c3538d661b62][afp_lec_1]] +* <2025-01-21 Tue> : [[id:3aef24fd-b220-4408-aa1e-c3538d661b62][AFP Lec 1]] diff --git a/20250120113936-afp_lab_1.org b/Uni/20250120113936-afp_lab_1.org old mode 100755 new mode 100644 similarity index 100% rename from 20250120113936-afp_lab_1.org rename to Uni/20250120113936-afp_lab_1.org diff --git a/20250121110241-afp_lec_1.org b/Uni/20250121110241-afp_lec_1.org old mode 100755 new mode 100644 similarity index 100% rename from 20250121110241-afp_lec_1.org rename to Uni/20250121110241-afp_lec_1.org diff --git a/20250128110828-afp_week2.org b/Uni/20250128110828-afp_week2.org old mode 100755 new mode 100644 similarity index 100% rename from 20250128110828-afp_week2.org rename to Uni/20250128110828-afp_week2.org diff --git a/20250128111008-afp_lec_2.org b/Uni/20250128111008-afp_lec_2.org old mode 100755 new mode 100644 similarity index 100% rename from 20250128111008-afp_lec_2.org rename to Uni/20250128111008-afp_lec_2.org diff --git a/20250218110239-afp_week5.org b/Uni/20250218110239-afp_week5.org old mode 100755 new mode 100644 similarity index 100% rename from 20250218110239-afp_week5.org rename to Uni/20250218110239-afp_week5.org diff --git a/20250218110346-afp_lec_5.org b/Uni/20250218110346-afp_lec_5.org old mode 100755 new mode 100644 similarity index 100% rename from 20250218110346-afp_lec_5.org rename to Uni/20250218110346-afp_lec_5.org diff --git a/20250329114733-ise.org b/Uni/20250329114733-ise.org old mode 100755 new mode 100644 similarity index 100% rename from 20250329114733-ise.org rename to Uni/20250329114733-ise.org diff --git a/20250329114848-ise_week_1.org b/Uni/20250329114848-ise_week_1.org old mode 100755 new mode 100644 similarity index 100% rename from 20250329114848-ise_week_1.org rename to Uni/20250329114848-ise_week_1.org diff --git a/20250329121843-ise_week_2.org b/Uni/20250329121843-ise_week_2.org old mode 100755 new mode 100644 similarity index 100% rename from 20250329121843-ise_week_2.org rename to Uni/20250329121843-ise_week_2.org diff --git a/20250329142725-ise_week_3.org b/Uni/20250329142725-ise_week_3.org old mode 100755 new mode 100644 similarity index 100% rename from 20250329142725-ise_week_3.org rename to Uni/20250329142725-ise_week_3.org diff --git a/20250329200158-ise_week_4.org b/Uni/20250329200158-ise_week_4.org old mode 100755 new mode 100644 similarity index 100% rename from 20250329200158-ise_week_4.org rename to Uni/20250329200158-ise_week_4.org diff --git a/20250331201944-ise_week_5.org b/Uni/20250331201944-ise_week_5.org old mode 100755 new mode 100644 similarity index 100% rename from 20250331201944-ise_week_5.org rename to Uni/20250331201944-ise_week_5.org diff --git a/20250331202447-ise_week_7.org b/Uni/20250331202447-ise_week_7.org old mode 100755 new mode 100644 similarity index 100% rename from 20250331202447-ise_week_7.org rename to Uni/20250331202447-ise_week_7.org diff --git a/20250403120140-fyp_report_planning.org b/Uni/20250403120140-fyp_report_planning.org old mode 100755 new mode 100644 similarity index 100% rename from 20250403120140-fyp_report_planning.org rename to Uni/20250403120140-fyp_report_planning.org diff --git a/Uni/20250723184233-advanced_networking.org b/Uni/20250723184233-advanced_networking.org new file mode 100644 index 0000000..70106d9 --- /dev/null +++ b/Uni/20250723184233-advanced_networking.org @@ -0,0 +1,35 @@ +:PROPERTIES: +:ID: 3acffb66-bc1a-4661-904f-c5447b3c3488 +:END: +#+title: Advanced Networking +#+filetags: :uni:networking: + +# Advanced Networking + +This module was taught in the first semester of my final year at university. There were a wide range of topics that were covered, and best efforts were made in not talking about the security aspects of networks, although it is the case that when we talk about networks we are talking about secure networks (who even needs insecure networks?). + +The following core topics were covered: + +1. Lower Layer Protocols + + - Packet vs Circuit Switching, Ethernet, layer models (DoD 4/5, OSI 7). + - Network Hardware: Switches, Routers, data/control/management plane. Software defined networks. + - LAN/WAN split, Arpanet, DoD, OSI. Why OSI Failed + - Link aggregation and VLANs + +2. IP Addressing + + - Addressing, routing, concepts. Why IPv6 is needed + - Address allocation, bootp, DHCP, SLAAC + - NAT and Proxying + +3. TCP/UDP + - UDP: applications, advantages and disadvantages + - TCP: applications, advantages and disadvantages, mechanisms and operation, sequence numbers, receive windows, slow start, window scaling, PAWS, timestamping, multipathing + - Demultiplexing, multiplexing + +4. DNS + - DNS: concepts, resource records, RR sets, basic operation, recursive and authoritative servers, caching, DNSSEC + +5. Higher layer protocols + - Basic operation of HTTP, FTP, SMTP diff --git a/all-files.json b/all-files.json old mode 100755 new mode 100644 index 5b9444d..e8acc7c --- a/all-files.json +++ b/all-files.json @@ -6,116 +6,126 @@ { "id": "7f756445-de36-4c17-a7c2-213e626d8498", "title": "2026 Targets", - "url": "/20260107182221-2026_targets.html" + "url": "/Misc/20260107182221-2026_targets.html" } ], "A": [ { "id": "effa2bf5-8b04-42d3-b9c1-17160dc4ddc2", "title": "Actual", - "url": "/20260101143401-actual_self_hosted.html" + "url": "/Misc/20260101143401-actual_self_hosted.html" }, { "id": "3acffb66-bc1a-4661-904f-c5447b3c3488", - "title": "advanced-networking", - "url": "/20250723184233-advanced_networking.html" + "title": "Advanced Networking", + "url": "/Uni/20250723184233-advanced_networking.html" }, { "id": "556d10d1-1c74-4d9f-a398-39cb3bd5d935", - "title": "afp", - "url": "/20250120110833-afp.html" + "title": "AFP (Advanced Functional Programming)", + "url": "/Uni/20250120110833-afp.html" + }, + { + "id": "6c272430-aff5-468b-90d3-5ff3a96152cf", + "title": "AFP Week 1", + "url": "/Uni/20250120111047-afp_week1.html" }, { "id": "f6c9e1a7-8465-4cef-9481-2b803d0c43d4", "title": "afp_lab_1", - "url": "/20250120113936-afp_lab_1.html" + "url": "/Uni/20250120113936-afp_lab_1.html" }, { "id": "3aef24fd-b220-4408-aa1e-c3538d661b62", "title": "afp_lec_1", - "url": "/20250121110241-afp_lec_1.html" + "url": "/Uni/20250121110241-afp_lec_1.html" }, { "id": "460f4a49-8ae4-444a-bf82-4e14ca7cad3f", "title": "afp_lec_2", - "url": "/20250128111008-afp_lec_2.html" + "url": "/Uni/20250128111008-afp_lec_2.html" }, { "id": "ed4c372b-0314-4b6e-9119-742f69b5e434", "title": "afp_lec_5", - "url": "/20250218110346-afp_lec_5.html" - }, - { - "id": "6c272430-aff5-468b-90d3-5ff3a96152cf", - "title": "afp_week1", - "url": "/20250120111047-afp_week1.html" + "url": "/Uni/20250218110346-afp_lec_5.html" }, { "id": "4bc71106-1d2b-4c71-836d-54b738fe5ff5", "title": "afp_week2", - "url": "/20250128110828-afp_week2.html" + "url": "/Uni/20250128110828-afp_week2.html" }, { "id": "1f395b8c-cf55-43eb-9430-dd9449f6b575", "title": "afp_week5", - "url": "/20250218110239-afp_week5.html" + "url": "/Uni/20250218110239-afp_week5.html" }, { "id": "c6cf8f7a-778f-4e83-b607-753ef8dbb3f1", "title": "Airflow", - "url": "/20251229180039-airflow.html" + "url": "/Career Concepts/20251229180039-airflow.html" }, { "id": "3b16e19a-62f0-4705-a451-a8790181941f", "title": "Airflow Dags", - "url": "/20251229180249-airflow_dags.html" + "url": "/Career Concepts/20251229180249-airflow_dags.html" }, { "id": "1ea42d73-3cd1-4cac-a6ee-028de21d08d5", "title": "Airflow Tasks", - "url": "/20251229180156-airflow_tasks.html" + "url": "/Career Concepts/20251229180156-airflow_tasks.html" }, { "id": "e7f2302b-16eb-476d-a7b9-be12f077819d", "title": "AOC Notes", - "url": "/20241210001150-aoc_notes.html" + "url": "/Notes/20241210001150-aoc_notes.html" }, { "id": "49b195c8-e116-40ca-86e8-62c65dbb5a4f", "title": "API Architecture", - "url": "/20260121173318-api_architecture.html" + "url": "/Career Concepts/20260121173318-api_architecture.html" + }, + { + "id": "e7f082e4-1b9f-4ebe-96d6-94d92e80a07e", + "title": "API Intro Notes", + "url": "/20260327110908-api_intro_notes.html" }, { "id": "56fabaf6-e8aa-45d0-a1c1-89f247f0a93f", "title": "APIM", - "url": "/20260115152626-apim.html" + "url": "/Career Concepts/20260115152626-apim.html" + }, + { + "id": "b2fd7038-42a8-4cbe-882b-92fbe2c12a11", + "title": "ASP.NET Core Web API Fundamental Notes", + "url": "/20260327114708-asp_net_core_6_apis_notes.html" } ], "B": [ { "id": "580cc3a5-af8e-4cbe-b5ad-5b06680e6c37", "title": "Backlog", - "url": "/20251101123637-backlog.html" + "url": "/Misc/20251101123637-backlog.html" }, { "id": "275988a8-59d8-40c8-a8b4-47118d6eb834", - "title": "big-o-complexity", - "url": "/20250804201706-big_o_complexity.html" + "title": "Big (O) - Time and Space Complexity", + "url": "/Career Concepts/20250804201706-big_o_complexity.html" }, { "id": "238ff7d8-db22-41e2-8aad-fc3c778e6248", "title": "book-recs", - "url": "/20250727174903-book_recs.html" + "url": "/Books/20250727174903-book_recs.html" }, { "id": "63314cff-3a3f-49b4-9e76-4a359c51f55f", "title": "Books MOC", - "url": "/20250727174809-books_moc.html" + "url": "/Books/20250727174809-books_moc.html" }, { "id": "bca8e7a6-0590-4630-ab49-210306ad21a2", "title": "bowling-kata", - "url": "/20250723185943-bowling_kata.html" + "url": "/Misc/20250723185943-bowling_kata.html" }, { "id": "b2fb976a-c23c-4275-8a53-da343c223b97", @@ -127,149 +137,149 @@ { "id": "5a207a1c-6f02-40d5-b42e-38daaa0aec10", "title": "C Notes", - "url": "/20241213005125-c_notes.html" + "url": "/Notes/20241213005125-c_notes.html" }, { "id": "f9838952-9753-471b-a2cc-d72e01a53ef6", "title": "career_capital", - "url": "/20250723183655-career_capital.html" + "url": "/Books/20250723183655-career_capital.html" }, { "id": "dd04d228-fff5-402a-929d-9d113a2ec965", "title": "career_moc", - "url": "/20250722221649-career_moc.html" + "url": "/Career Concepts/20250722221649-career_moc.html" }, { "id": "2767b5ac-f2c9-4b1e-ab87-82c43cdec4c1", "title": "CI/CD Example", - "url": "/20260305102210-cicd_example.html" + "url": "/Career Concepts/20260305102210-cicd_example.html" }, { "id": "5b714c6c-7eaf-4f3f-b4f6-2166ff3a9963", "title": "CI/CD Summary", - "url": "/20260305111610-cicd_summary.html" + "url": "/Career Concepts/20260305111610-cicd_summary.html" }, { "id": "dd55d635-59de-4ed9-8ff0-423782c2e0ae", "title": "clean-code", - "url": "/20250727221512-clean_code.html" + "url": "/Books/20250727221512-clean_code.html" }, { "id": "22737796-6D31-49D5-84F2-F7BC73E45144", "title": "Concepts", - "url": "/20260101010049-concepts.html" + "url": "/Career Concepts/20260101010049-concepts.html" } ], "D": [ { "id": "e448cd99-afee-4702-947f-644bb34dc1aa", "title": "Database MOC", - "url": "/20250727122406-database_moc.html" + "url": "/Career Concepts/20250727122406-database_moc.html" }, { "id": "b4858f6a-b05c-47f2-972e-905e0bb2c352", "title": "Database Permissions, Roles, and Accounts", - "url": "/20260305130457-database_perms_roles_accounts.html" + "url": "/Career Concepts/20260305130457-database_perms_roles_accounts.html" }, { "id": "d4f96bfb-b83d-449b-9f74-f602a1a3c2d3", "title": "deliberate_practice", - "url": "/20250723183755-deliberate_practice.html" + "url": "/Books/20250723183755-deliberate_practice.html" }, { "id": "631b2086-4b8f-4fe3-829d-be1dc014e293", "title": "Design patterns", - "url": "/20251223215636-design_patterns_notes.html" + "url": "/Career Concepts/20251223215636-design_patterns_notes.html" } ], "E": [ + { + "id": "7e79e4c5-383d-450f-882c-33d4f87ba1b5", + "title": "Emacs ELISP", + "url": "/Emacs/20250326002128-emacs_stuff_elisp.html" + }, + { + "id": "45CC3AF5-5E20-4B03-A36C-8D4BDD5CBB13", + "title": "Emacs Evil Mode", + "url": "/Emacs/20250420012258-emacs_stuff_evil.html" + }, { "id": "8e5e9498-ff3c-48e7-aab5-6e94b2e41ccb", "title": "Emacs GTD", - "url": "/20241210004453-gtd.html" + "url": "/Emacs/20241210004453-gtd.html" + }, + { + "id": "966175d4-3b58-4abc-9b41-08cbf328dd87", + "title": "Emacs Keybindings", + "url": "/Emacs/20250218174735-emacs_stuff_keybindings.html" + }, + { + "id": "2ab0fa3f-8ac6-4af2-8cd4-1dd490fb19c3", + "title": "Emacs Magit", + "url": "/Emacs/20250329231658-emacs_stuff_magit.html" }, { "id": "8fa3f476-6152-45f4-b618-50f1e4bce46c", "title": "Emacs MOC", - "url": "/20241210004247-emacs_moc.html" + "url": "/Emacs/20241210004247-emacs_moc.html" + }, + { + "id": "7d2e867e-f091-4362-a583-453f732207fe", + "title": "Emacs ORG Publish", + "url": "/Emacs/20250806155335-emacs_stuff_org_publish.html" }, { "id": "034abe27-ca14-4dc0-9a3f-b8d0e1f26342", "title": "Emacs Org Roam", - "url": "/20241210004329-org_roam.html" - }, - { - "id": "7e79e4c5-383d-450f-882c-33d4f87ba1b5", - "title": "emacs-stuff-elisp", - "url": "/20250326002128-emacs_stuff_elisp.html" - }, - { - "id": "45CC3AF5-5E20-4B03-A36C-8D4BDD5CBB13", - "title": "emacs-stuff-evil", - "url": "/20250420012258-emacs_stuff_evil.html" - }, - { - "id": "966175d4-3b58-4abc-9b41-08cbf328dd87", - "title": "emacs-stuff-keybindings", - "url": "/20250218174735-emacs_stuff_keybindings.html" - }, - { - "id": "2ab0fa3f-8ac6-4af2-8cd4-1dd490fb19c3", - "title": "emacs-stuff-magit", - "url": "/20250329231658-emacs_stuff_magit.html" - }, - { - "id": "7d2e867e-f091-4362-a583-453f732207fe", - "title": "emacs-stuff-org-publish", - "url": "/20250806155335-emacs_stuff_org_publish.html" + "url": "/Emacs/20241210004329-org_roam.html" } ], "F": [ { "id": "7d199fbe-b0e7-48fd-b8a1-793044dbea01", "title": "fyp", - "url": "/20241210012703-fyp.html" + "url": "/Uni/20241210012703-fyp.html" }, { "id": "26b2ed9a-cb81-4c43-bc63-6b3c8ffa3bf1", "title": "fyp-report-planning", - "url": "/20250403120140-fyp_report_planning.html" + "url": "/Uni/20250403120140-fyp_report_planning.html" } ], "G": [ { "id": "74ec625c-3559-4570-8f6e-8272f4859ea7", "title": "Gitea Notes", - "url": "/20260101194248-gitea.html" + "url": "/Misc/20260101194248-gitea.html" }, { "id": "ee6047b0-c878-4ec8-a1cf-9daf5c8f5b8e", "title": "Github Notes", - "url": "/20241220234456-github_notes.html" + "url": "/Notes/20241220234456-github_notes.html" }, { "id": "30c28e5e-0b1c-43ae-b3bd-eb31023f8b73", "title": "gpg-encryption", - "url": "/20250516161728-gpg_encryption.html" + "url": "/Linux/20250516161728-gpg_encryption.html" } ], "H": [ { "id": "347d2663-515b-4d9a-9ee9-7706ee86a845", "title": "Haskell Notes", - "url": "/20241212013207-haskell_notes.html" + "url": "/Notes/20241212013207-haskell_notes.html" }, { "id": "086ca3ca-39ec-4d37-b56d-b6d9f51e6873", "title": "how-to-solve-leetcode", - "url": "/20250804212215-how_to_solve_leetcode.html" + "url": "/Notes/20250804212215-how_to_solve_leetcode.html" } ], "I": [ { "id": "9d5aae0f-4ae1-49a5-a047-9099baad0a06", "title": "i3-wm", - "url": "/20250213124335-i3_wm.html" + "url": "/Linux/20250213124335-i3_wm.html" }, { "id": "DE792A73-FD00-4048-82D8-AB6E84E869F2", @@ -279,410 +289,410 @@ { "id": "c69e4c4d-2fb4-4cf1-a835-a235cf6db8e9", "title": "ISE", - "url": "/20250329114733-ise.html" + "url": "/Uni/20250329114733-ise.html" }, { "id": "0e70c535-b145-42d9-a9ed-fe48cddbb1a5", "title": "ISE Week 5", - "url": "/20250331201944-ise_week_5.html" + "url": "/Uni/20250331201944-ise_week_5.html" }, { "id": "06b2a012-4e8a-4a8a-9494-de7ed9fbe1d3", "title": "ise_week_1", - "url": "/20250329114848-ise_week_1.html" + "url": "/Uni/20250329114848-ise_week_1.html" }, { "id": "f308642d-fcf3-410b-b154-d60582e112a2", "title": "ise_week_2", - "url": "/20250329121843-ise_week_2.html" + "url": "/Uni/20250329121843-ise_week_2.html" }, { "id": "1d0fa257-579f-49f3-b8fd-a3b68ddccf10", "title": "ise_week_3", - "url": "/20250329142725-ise_week_3.html" + "url": "/Uni/20250329142725-ise_week_3.html" }, { "id": "ebf874d9-0554-47f0-be8b-5c9a948738bf", "title": "ise_week_4", - "url": "/20250329200158-ise_week_4.html" + "url": "/Uni/20250329200158-ise_week_4.html" }, { "id": "9ad3f3f1-55f7-4114-bc8c-17250b6dd25d", "title": "ise_week_7", - "url": "/20250331202447-ise_week_7.html" + "url": "/Uni/20250331202447-ise_week_7.html" } ], "J": [ - { - "id": "ae343652-96fe-4341-8a36-ec3a1abd0dc6", - "title": "Java MOC", - "url": "/20250402185735-java_moc.html" - }, { "id": "7b8de14c-a73e-4c92-a403-a9a1c419c0b3", "title": "java-junit-testing", - "url": "/20250723190656-java_junit_testing.html" + "url": "/Misc/20250723190656-java_junit_testing.html" }, { "id": "5cfd7f6f-f5ac-4f18-90f9-be9a31dd238e", "title": "java-portswrigger-test", - "url": "/20250723190203-java_portswrigger_test.html" + "url": "/Misc/20250723190203-java_portswrigger_test.html" + }, + { + "id": "ae343652-96fe-4341-8a36-ec3a1abd0dc6", + "title": "java_moc", + "url": "/Notes/20250402185735-technical_java_notes.html" }, { "id": "f9897f8e-2b63-4ad2-a55f-3787c4ac235f", "title": "job_application_cover_letters", - "url": "/20241211161232- job_application_cover_letters.html" + "url": "/Misc/20241211161232- job_application_cover_letters.html" } ], "K": [ { "id": "0217f537-442a-4593-8c69-d481f0d1f2a8", "title": "keyboard", - "url": "/20251122223053-keyboard.html" + "url": "/Misc/20251122223053-keyboard.html" } ], "L": [ { "id": "63456626-b34e-46d9-b85e-0f1f5724aa83", "title": "lazy_evaluation", - "url": "/20241212013902-lazy_evaluation.html" + "url": "/Notes/20241212013902-lazy_evaluation.html" }, { "id": "9d1cfccc-8da7-41a3-b435-9857f0abe441", "title": "Leetcode Notes", - "url": "/20241210001206-leetcode_notes.html" + "url": "/Notes/20241210001206-leetcode_notes.html" }, { "id": "93a43a24-6861-40c4-b45b-581977bb55cf", "title": "leetcode-arrays", - "url": "/20250804212606-leetcode_arrays.html" + "url": "/Notes/20250804212606-leetcode_arrays.html" }, { "id": "363dbdfa-f23c-4f7e-a6f3-6d34f78984bb", "title": "Library", - "url": "/20250724230557-books_org_agenda.html" + "url": "/Books/20250724230557-books_org_agenda.html" }, { "id": "bdb493df-db92-4c93-9558-0b10fdff3048", "title": "Linux MOC", - "url": "/20250417173809-linux_stuff.html" + "url": "/Linux/20250417173809-linux_stuff.html" }, { "id": "569a4a57-1843-4821-8259-17762855985e", "title": "linux-arch-linux", - "url": "/20250703183239-linux_arch_linux.html" + "url": "/Linux/20250703183239-linux_arch_linux.html" } ], "M": [ { "id": "bcd41e87-120c-455c-8898-996ddaa41f75", "title": "maven-pom-file", - "url": "/20250723171109-maven_pom_file.html" + "url": "/Notes/20250723171109-maven_pom_file.html" }, { "id": "ABF4A0BE-0309-48A6-92ED-76031B3D2F86", "title": "Microlise MOC", - "url": "/20251002154125-microlise_moc.html" + "url": "/Misc/20251002154125-microlise_moc.html" }, { "id": "f877240e-c2c8-4087-84e5-4b1ca3fcd4ed", "title": "microlise-assessment", - "url": "/20250430001952-microlise_assessment.html" + "url": "/Misc/20250430001952-microlise_assessment.html" }, { "id": "08415f5c-986e-45a6-8ea1-f3bedcc996f0", "title": "Misc MOC", - "url": "/20250918120519-misc_moc.html" + "url": "/Misc/20250918120519-misc_moc.html" } ], "N": [ { "id": "0880f089-a5ad-49cd-8ce3-f020a5941313", "title": "Networking MOC", - "url": "/20250727121051-networking_moc.html" + "url": "/Notes/20250727121051-networking_moc.html" }, { "id": "a087da71-bcfb-4ddf-9565-b82113d5d27f", "title": "neuroplasticity", - "url": "/20250723185056-neuroplasticity.html" + "url": "/Books/20250723185056-neuroplasticity.html" }, { "id": "56f39be4-1108-4020-be5a-1f3a0fbf96fa", "title": "Nextcloud", - "url": "/20250727120306-nextcloud.html" + "url": "/Linux/20250727120306-nextcloud.html" }, { "id": "565eaccd-8cf6-4dbb-bc66-a4b37367ce6b", "title": "Non-Technical MOC", - "url": "/20250806111925-non_technical_moc.html" + "url": "/Misc/20250806111925-non_technical_moc.html" } ], "O": [ { "id": "a9829b5d-690d-4a21-ba94-ac8beac4d439", "title": "Old NGINX Config", - "url": "/20251109205925-old_nginx_code.html" + "url": "/Misc/20251109205925-old_nginx_code.html" }, { "id": "2c2d8df4-ad36-40ab-9f30-8a047b372956", "title": "old_nextcloud_server_code", - "url": "/20251019114758-old_nextcloud_server_code.html" + "url": "/Misc/20251019114758-old_nextcloud_server_code.html" } ], "P": [ { "id": "5f8f7d8a-5dfc-49a4-a7a6-33373a1d7c8d", "title": "Personal Operating System", - "url": "/20260211114817-personal_operating_system.html" + "url": "/Misc/20260211114817-personal_operating_system.html" }, { "id": "939e301b-6463-46a8-b57e-0af606e7e7ef", "title": "Postgres", - "url": "/20250723200800-postgres.html" + "url": "/Career Concepts/20250723200800-postgres.html" }, { "id": "2BFB84B2-2129-4AE3-8E69-290CA5BF9747", "title": "pre_work_prep_microlise", - "url": "/20251002154204-pre_work_prep_microlise.html" + "url": "/Misc/20251002154204-pre_work_prep_microlise.html" }, { "id": "d63abaad-15e8-45d8-aafb-c634164ec0c0", "title": "Programming Projects", - "url": "/20260117194854-programming_projects.html" + "url": "/Misc/20260117194854-programming_projects.html" }, { "id": "45eefd5b-a3d8-4b83-84ea-5a6984025755", "title": "Proverbs", - "url": "/20260307165727-proverbs.html" + "url": "/Misc/20260307165727-proverbs.html" }, { "id": "125c81dc-c14f-4b4d-93c6-0a2b157735ac", "title": "python-dictionary", - "url": "/20250805141906-python_dictionary.html" + "url": "/Notes/20250805141906-python_dictionary.html" }, { "id": "9d534e89-7f0b-494c-bff6-7b3be05b85d1", "title": "python-lambda", - "url": "/20250805143741-python_lambda.html" + "url": "/Notes/20250805143741-python_lambda.html" }, { "id": "3a41407c-661e-416a-80d2-4c7a137d153a", "title": "python-set", - "url": "/20250804214537-python_set.html" + "url": "/Notes/20250804214537-python_set.html" }, { "id": "3bbc6099-0187-4bf2-9282-97e5fa443f72", "title": "python-sorted-function", - "url": "/20250805143427-python_sorted_function.html" + "url": "/Notes/20250805143427-python_sorted_function.html" } ], "R": [ { "id": "b31d6c3f-9bc3-4006-aaaf-d56168249e3a", "title": "Recipes Cookbook", - "url": "/20260307233451-recipes_cookbook.html" + "url": "/Misc/20260307233451-recipes_cookbook.html" }, { "id": "EA93341B-20C0-48A2-BD88-F24ED3C540DA", "title": "Recipes Done", - "url": "/20250719175023-recipes_done.html" + "url": "/Misc/20250719175023-recipes_done.html" }, { "id": "F7D68FF4-CAD0-4791-BAE4-AC20B84A8785", "title": "Recipes Ideas", - "url": "/20250719174944-recipes_ideas.html" + "url": "/Misc/20250719174944-recipes_ideas.html" }, { "id": "65F747B1-3CB2-429A-9E26-ED8BC169E689", "title": "Recipes MOC", - "url": "/20250717230336-recipes_moc.html" + "url": "/Misc/20250717230336-recipes_moc.html" }, { "id": "6a5bf6dd-d0ec-43e4-8e07-9956f4715f10", "title": "RESTful APIs", - "url": "/20260305132058-restful_api.html" + "url": "/Career Concepts/20260305132058-restful_api.html" }, { "id": "3a8274ef-f2fe-486d-9caf-0c56982b9917", "title": "RSS Articles", - "url": "/20260111204228-rss_articles.html" + "url": "/Misc/20260111204228-rss_articles.html" } ], "S": [ { "id": "99533f2d-a4e8-41d0-a605-c7d4cef6f995", "title": "self_hosting", - "url": "/20250723190927-self_hosting.html" + "url": "/Linux/20250723190927-self_hosting.html" }, { "id": "9a71daa4-d9d4-4706-98f1-72e3d4eda9bc", "title": "Server Backend", - "url": "/20260104155940-server_backend.html" + "url": "/Linux/20260104155940-server_backend.html" }, { "id": "f09cb4ed-1407-4187-9002-de2c5db13a8f", "title": "Server MOC", - "url": "/20251019114736-server_moc.html" + "url": "/Linux/20251019114736-server_moc.html" }, { "id": "2d7f1ccc-99d7-4c45-8fe7-4b87080edb01", "title": "so_good_they_cant_ignore_you", - "url": "/20250723182408-so_good_they_cant_ignore_you.html" + "url": "/Books/20250723182408-so-good-they-cant-ignore-you.html" }, { "id": "efe0360d-8d81-4372-833d-ad58e67d17c6", "title": "socket_programming_in_c", - "url": "/20241213005156-socket_programming_in_c.html" + "url": "/Notes/20241213005156-socket_programming_in_c.html" }, { "id": "6820973F-613E-441A-BC1D-8FE5CD9BD6F7", - "title": "solid_principles", - "url": "/20260101012549-solid_principles.html" + "title": "Solid Principles", + "url": "/Career Concepts/20260101012549-solid_principles.html" }, { "id": "F3875F0F-5C9E-4BB1-A79C-6000B9558115", "title": "solid_principles_examples", - "url": "/20260101012731-solid_principles_examples.html" + "url": "/Career Concepts/20260101012731-solid_principles_examples.html" }, { "id": "acba0d25-08db-4784-8cc2-fe5c437ba723", "title": "stanford_marshmallow_experiment", - "url": "/20250723184430-stanford_marshmallow_experiment.html" + "url": "/Books/20250723184430-stanford_marshmallow_experiment.html" }, { "id": "bf277242-4f09-46a2-aa6b-1d75ce0025ac", "title": "systemd_services", - "url": "/20250428133236-systemd_services.html" + "url": "/Linux/20250428133236-systemd_services.html" } ], "T": [ { "id": "37495d5f-2a77-40bc-b45c-8163189bbe6b", "title": "Technical Commonplace", - "url": "/20251223220531-technical_commonplace.html" + "url": "/Misc/20251223220531-technical_commonplace.html" }, { "id": "2f285f04-fcf4-4ade-a1ac-2c50b43d529a", "title": "Technical MOC", - "url": "/20241210001045-technical_moc.html" + "url": "/Misc/20241210001045-technical_moc.html" }, { "id": "2729599d-ae2b-4f22-b73d-bf22d81e0767", "title": "Test Driven Development", - "url": "/20250723185829-test_driven_development.html" + "url": "/Misc/20250723185829-test_driven_development.html" }, { "id": "EC9D851F-3A2E-4F32-A584-76F6F7A08E30", "title": "the_clean_coder", - "url": "/20250715223949-the_clean_coder.html" + "url": "/Books/20250715223949-the_clean_coder.html" }, { "id": "455ef38f-9a5f-4f62-afe9-25e2261e1282", "title": "the_science_of_self_discipline", - "url": "/20241231172543-the_science_of_self_discipline.html" + "url": "/Books/20241231172543-the_science_of_self_discipline.html" }, { "id": "fc92a943-61ac-462a-b6e5-8be46069f2ca", "title": "Timetable", - "url": "/20260211124505-timetable.html" + "url": "/Misc/20260211124505-timetable.html" }, { "id": "5443ed1c-bb7f-4eb4-9c96-d12648dd2291", "title": "tpis", - "url": "/20241210152713-tpis.html" + "url": "/Uni/20241210152713-tpis.html" } ], "U": [ { "id": "4a8edaed-9ebd-402b-9c5f-7a0cb4399102", "title": "uml_fyp", - "url": "/20241210232054-uml_fyp.html" + "url": "/Uni/20241210232054-uml_fyp.html" }, { "id": "797d6e3e-98eb-4bc7-88b6-e096ef7306ad", "title": "uni_moc", - "url": "/20241210152650-uni_moc.html" + "url": "/Uni/20241210152650-uni_moc.html" }, { "id": "d939e477-d1e9-43ea-960e-8727246d12a3", "title": "useful-c-imports", - "url": "/20251214210526-useful_c_imports.html" + "url": "/Misc/20251214210526-useful_c_imports.html" } ], "V": [ { "id": "e12ef44d-69a4-45c8-a823-c810d2c3857c", "title": "Vaultwarden", - "url": "/20260227103506-vaultwarden.html" + "url": "/Linux/20260227103506-vaultwarden.html" } ], "W": [ { "id": "7612a9a6-ae70-4525-93a0-81bac857df39", "title": "wacom-notes", - "url": "/20250417173821-wacom_notes.html" + "url": "/Linux/20250417173821-wacom_notes.html" }, { "id": "348df473-6443-4f4a-b366-95397b574989", "title": "web-port-notes", - "url": "/20241217234535-web_port_notes.html" + "url": "/Notes/20241217234535-web_port_notes.html" }, { "id": "c1de3972-e932-48fd-8065-3d89dad58007", "title": "wedding_moc", - "url": "/20250918120706-wedding_moc.html" + "url": "/Misc/20250918120706-wedding_moc.html" }, { "id": "8CE93986-280B-45BD-9DF2-5D06586DDDE7", "title": "workflow-moc", - "url": "/20250926151524-workflow_moc.html" + "url": "/Misc/20250926151524-workflow_moc.html" }, { "id": "b2db0b0b-c179-43ab-9e2b-22bbaac69bcb", "title": "wp-emacs-config-blorg", - "url": "/20241217234944-wp_emacs_config_blorg.html" + "url": "/Notes/20241217234944-wp_emacs_config_blorg.html" }, { "id": "D02B89DC-84D0-4211-A902-B9399F4179CA", "title": "wp-emotional-intelligence", - "url": "/20250314230952-wp_emotional_intelligence.html" + "url": "/Notes/20250314230952-wp_emotional_intelligence.html" }, { "id": "CD093B85-BF68-4EAB-AABE-733C7BFC99DE", "title": "wp-growth-mindset", - "url": "/20250314223811-wp_growth_mindset.html" + "url": "/Notes/20250314223811-wp_growth_mindset.html" }, { "id": "1ee754f9-f30f-4976-850b-d18d01a834d2", "title": "wp-new-emacs-config-blorg", - "url": "/20250214155617-wp_new_emacs_config_blorg.html" + "url": "/Notes/20250214155617-wp_new_emacs_config_blorg.html" }, { "id": "b292f5c6-0c27-439c-8274-2150eb45e20d", "title": "wp-prefront-cortex-blorg", - "url": "/20250111213016-wp_prefront_cortex_blog.html" + "url": "/Notes/20250111213016-wp_prefront_cortex_blog.html" }, { "id": "462F091B-9156-48B3-8665-0BE36C95C182", "title": "wp-sadness", - "url": "/20250412234351-wp_sadness.html" + "url": "/Notes/20250412234351-wp_sadness.html" }, { "id": "cfc4ce06-7862-49b7-9a4f-e515d690cd38", "title": "wp-urge-surfing-blorg", - "url": "/20250226184629-wp_urge_surfing_blorg.html" + "url": "/Notes/20250226184629-wp_urge_surfing_blorg.html" }, { "id": "8CD2F4C4-22C2-4ECC-8F5F-C4779F8AC0F1", "title": "wp-week-12-reflection", - "url": "/20250324041724-wp_week_12_reflections.html" + "url": "/Notes/20250324041724-wp_week_12_reflections.html" } ], "X": [ { "id": "F32F8F09-3DEC-4FD1-8CFA-401A316E906B", - "title": "xor", - "url": "/20260101011126-xor.html" + "title": "XOR", + "url": "/Career Concepts/20260101011126-xor.html" } ] } diff --git a/all-files.org b/all-files.org old mode 100755 new mode 100644 diff --git a/assets/2_to_1.svg b/assets/2_to_1.svg old mode 100755 new mode 100644 diff --git a/assets/Big-O-Notation-3130482830.png b/assets/Big-O-Notation-3130482830.png old mode 100755 new mode 100644 diff --git a/assets/Screenshot_20251227_153037.png b/assets/Screenshot_20251227_153037.png old mode 100755 new mode 100644 diff --git a/assets/career-notes/api-layers.png b/assets/career-notes/api-layers.png old mode 100755 new mode 100644 diff --git a/assets/career/APIOps.png b/assets/career/APIOps.png old mode 100755 new mode 100644 diff --git a/assets/career/Screenshot 2026-01-14 154800.png b/assets/career/Screenshot 2026-01-14 154800.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/adapter-pattern-2.png b/assets/design-patterns/adapter-pattern-2.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/adapter-pattern.png b/assets/design-patterns/adapter-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/command-pattern.png b/assets/design-patterns/command-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/composite-pattern.png b/assets/design-patterns/composite-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/decorator-pattern.png b/assets/design-patterns/decorator-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/decorator-problem.png b/assets/design-patterns/decorator-problem.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/facade-pattern.png b/assets/design-patterns/facade-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/factory-pattern.png b/assets/design-patterns/factory-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/iterator-pattern.png b/assets/design-patterns/iterator-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/observer-pattern.png b/assets/design-patterns/observer-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/proxy-pattern.png b/assets/design-patterns/proxy-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/singleton-pattern.png b/assets/design-patterns/singleton-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/state-pattern.png b/assets/design-patterns/state-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/structure-pattern.png b/assets/design-patterns/structure-pattern.png old mode 100755 new mode 100644 diff --git a/assets/design-patterns/template-method-pattern.png b/assets/design-patterns/template-method-pattern.png old mode 100755 new mode 100644 diff --git a/assets/file_example_MOV_480_700kB.mov b/assets/file_example_MOV_480_700kB.mov new file mode 100644 index 0000000..28c89a1 Binary files /dev/null and b/assets/file_example_MOV_480_700kB.mov differ diff --git a/assets/file_example_MOV_480_700kB.mp4 b/assets/file_example_MOV_480_700kB.mp4 new file mode 100644 index 0000000..1557356 Binary files /dev/null and b/assets/file_example_MOV_480_700kB.mp4 differ diff --git a/assets/file_example_MP3_700KB.mp3 b/assets/file_example_MP3_700KB.mp3 new file mode 100644 index 0000000..ab94045 Binary files /dev/null and b/assets/file_example_MP3_700KB.mp3 differ diff --git a/assets/file_example_MP4_480_1_5MG.mp4 b/assets/file_example_MP4_480_1_5MG.mp4 new file mode 100644 index 0000000..b11552f Binary files /dev/null and b/assets/file_example_MP4_480_1_5MG.mp4 differ diff --git a/assets/git-cheat-sheet-1.png b/assets/git-cheat-sheet-1.png old mode 100755 new mode 100644 diff --git a/assets/git-cheat-sheet-2.png b/assets/git-cheat-sheet-2.png old mode 100755 new mode 100644 diff --git a/assets/gr.png b/assets/gr.png old mode 100755 new mode 100644 diff --git a/assets/icons/icons8-z-key-64.png b/assets/icons/icons8-z-key-64.png old mode 100755 new mode 100644 diff --git a/assets/scripts/bigger-picture.min.js b/assets/scripts/bigger-picture.min.js old mode 100755 new mode 100644 diff --git a/assets/scripts/cookbook.js b/assets/scripts/cookbook.js index 24f8ed1..402ea29 100644 --- a/assets/scripts/cookbook.js +++ b/assets/scripts/cookbook.js @@ -1,7 +1,12 @@ /** - * cookbook.js - * Works both as a direct page load AND when injected as a stacked pane - * by script.js (which fetches pages and injects only #content). + * cookbook.js — fixed for the new tab-based layout + * + * Changes vs original: + * 1. initCookbook() is exported so script.js can call it after tab content loads + * 2. cellValue() scans ALL tr elements (not just tbody) — org-mode hides thead via CSS + * but the rows are still in the DOM under thead + * 3. watchForPanes() now watches #content-area (the new tab container) instead of .stack-track + * 4. Toolbar falls back to inserting before the first .outline-3 if .outline-2 is absent */ (function () { @@ -10,7 +15,6 @@ // ── Core init — scoped to a content root ────────────────────────────────── function initCookbook(root) { - // Already initialised on this root? if (root.dataset.cbInit) return; root.dataset.cbInit = "1"; @@ -22,7 +26,9 @@ // ── Helpers ───────────────────────────────────────────────────────────── function cellValue(table, label) { - for (const row of table.querySelectorAll("tbody tr")) { + // Scan ALL tr elements — org-mode thead is hidden via CSS but rows are + // still in the DOM there; relying only on tbody misses them. + for (const row of table.querySelectorAll("tr")) { const cells = row.querySelectorAll("td"); if (cells.length >= 2 && cells[0].textContent.trim() === label) return cells[1].textContent.trim(); @@ -61,8 +67,17 @@ `; - const firstSection = root.querySelector(".outline-2"); - if (firstSection) firstSection.parentNode.insertBefore(toolbar, firstSection); + // Insert before first .outline-2; fall back to first .outline-3 + const insertTarget = + root.querySelector(".outline-2") || + root.querySelector(".outline-3"); + + if (insertTarget) { + insertTarget.parentNode.insertBefore(toolbar, insertTarget); + } else { + // Last resort: prepend into root + root.prepend(toolbar); + } const searchInput = toolbar.querySelector(".cb-search"); const filterBtns = toolbar.querySelectorAll(".cb-filter-btn"); @@ -95,7 +110,7 @@ const cooked = isCooked(table); const title = (block.querySelector("h3")?.textContent ?? "").toLowerCase(); const kwRaw = cellValue(table, "Keywords"); - const kwLow = kwRaw.toLowerCase(); + const kwLow = kwLow = kwRaw.toLowerCase(); if (activeFilter === "cooked" && !cooked) { hide(block); return; } if (activeFilter === "uncooked" && cooked) { hide(block); return; } @@ -113,7 +128,6 @@ shown++; }); - // Hide category headings with no visible recipes root.querySelectorAll(".outline-2").forEach(section => { const hasVisible = Array.from(section.querySelectorAll(".outline-3")) .some(b => b.style.display !== "none"); @@ -184,7 +198,6 @@ // ── Entry points ────────────────────────────────────────────────────────── - // 1. Direct page load — #content is already in the DOM function tryInitOnContent() { const content = document.getElementById("content"); if (content && content.querySelector("table.recipe-meta")) { @@ -192,39 +205,57 @@ } } - // 2. Stacked pane — script.js fetches a page and appends a new
- // with the #content inside it. Watch for that. function watchForPanes() { - const track = document.querySelector(".stack-track"); - if (!track) return; + // Watch #content-area — this is where script.js appends new .tab-content divs. + // Falls back to watching document.body if #content-area isn't ready yet. + const getTrack = () => + document.getElementById("content-area") || document.body; - const observer = new MutationObserver(mutations => { - mutations.forEach(m => { - m.addedNodes.forEach(node => { - if (node.nodeType !== 1) return; - // script.js appends an
- // containing a div#content - const content = node.id === "content" - ? node - : node.querySelector("#content, .content"); - if (content && content.querySelector("table.recipe-meta")) { - initCookbook(content); - } + const observe = (track) => { + const observer = new MutationObserver(mutations => { + mutations.forEach(m => { + m.addedNodes.forEach(node => { + if (node.nodeType !== 1) return; + // script.js appends .tab-content divs containing a div#content + const content = + (node.id === "content" ? node : null) || + node.querySelector("#content, .content"); + if (content && content.querySelector("table.recipe-meta")) { + initCookbook(content); + } + }); }); }); - }); + observer.observe(track, { childList: true, subtree: true }); + }; - observer.observe(track, { childList: true, subtree: true }); + const track = document.getElementById("content-area"); + if (track) { + observe(track); + } else { + // content-area is built by script.js after DOMContentLoaded; + // wait for it to appear then start observing. + const bodyObserver = new MutationObserver(() => { + const area = document.getElementById("content-area"); + if (area) { + bodyObserver.disconnect(); + observe(area); + } + }); + bodyObserver.observe(document.body, { childList: true, subtree: false }); + } } - // Run both + // Expose for direct calls from script.js if needed: + // window.initCookbook(contentEl); + window.initCookbook = initCookbook; + if (document.readyState === "loading") { document.addEventListener("DOMContentLoaded", () => { tryInitOnContent(); watchForPanes(); }); } else { - // Already parsed (script has `defer` but DOM may already be ready) tryInitOnContent(); watchForPanes(); } diff --git a/assets/scripts/gallery-init.js b/assets/scripts/gallery-init.js old mode 100755 new mode 100644 index 2cb8df9..d258705 --- a/assets/scripts/gallery-init.js +++ b/assets/scripts/gallery-init.js @@ -4,18 +4,33 @@ document.addEventListener('DOMContentLoaded', () => { return; } + // --- Shared helpers for video detection + mime typing --- + const VIDEO_EXTENSIONS = ['mp4', 'webm', 'mov', 'm4v', 'ogv']; + + function isVideo(href) { + if (!href) return false; + const clean = String(href).toLowerCase().split('#')[0].split('?')[0]; + return VIDEO_EXTENSIONS.some(ext => clean.endsWith('.' + ext)); + } + + function mimeFromExt(href) { + const ext = String(href).toLowerCase().split('#')[0].split('?')[0].split('.').pop(); + switch (ext) { + case 'mp4': case 'm4v': return 'video/mp4'; + case 'webm': return 'video/webm'; + case 'ogv': return 'video/ogg'; + case 'mov': return 'video/quicktime'; + default: return 'video/*'; + } + } + + // ------------------------------------------------------- + function setupGalleries(root = document) { const imgs = root.querySelectorAll('.figure img, img.org-svg'); - const VIDEO_EXTENSIONS = ['mp4','webm','mov','m4v','ogv']; - function isVideo(href){ - if(!href) return false; - href = href.toLowerCase(); - return VIDEO_EXTENSIONS.some(ext => href.endsWith('.' + ext)); - } imgs.forEach((img) => { if (img.closest('a')) return; - const a = document.createElement('a'); const href = img.currentSrc || img.src; a.href = href; @@ -23,10 +38,9 @@ document.addEventListener('DOMContentLoaded', () => { a.dataset.alt = img.alt || ''; const setDims = () => { - a.dataset.width = img.naturalWidth || img.width || 1920; - a.dataset.height = img.naturalHeight || img.height || 1080; + a.dataset.width = img.naturalWidth || img.width || 1920; + a.dataset.height = img.naturalHeight || img.height || 1080; }; - if (img.complete) setDims(); else img.addEventListener('load', setDims); @@ -36,163 +50,153 @@ document.addEventListener('DOMContentLoaded', () => { }); const containers = root.querySelectorAll('main, article, .content, body'); - containers.forEach((container) => { - //const links = Array.from(container.querySelectorAll('.figure a, a:has(img.org-svg)')); const links = Array.from(container.querySelectorAll( - '.figure a, a:has(img.org-svg), a[href$=".mp4"], a[href$=".webm"], a[href$=".mov"], a[href$=".m4v"], a[href$=".ogv"]' + '.figure a, a:has(img.org-svg), a[href$=".mp4"], a[href$=".webm"], a[href$=".mov"], a[href$=".m4v"], a[href$=".ogv"]' )); if (!links.length) return; links.forEach((link) => { - if (link.dataset.bpBound) return; - link.dataset.bpBound = 'true'; - - link.addEventListener('click', (e) => { + if (link.dataset.bpBound) return; + link.dataset.bpBound = 'true'; + link.addEventListener('click', (e) => { e.preventDefault(); - bp.open({ items: links, el: link, caption: (el) => el.querySelector('img')?.alt || el.title || '', maxZoom: 40, - onOpen(containerEl){ - const linkEl = bp.currItem; - const href = linkEl?.href || ""; - - if (isVideo(href)) { - teardownRotation(); - - const htmlLayer = containerEl.querySelector(".bp-html"); - const imgLayer = containerEl.querySelector(".bp-img"); - - if (imgLayer) imgLayer.style.display = "none"; - - htmlLayer.innerHTML = ` - - `; - return; - } - - setupRotation(containerEl); - enhanceSVG(containerEl); - } + onOpen(containerEl) { + const linkEl = bp.currItem; + const href = linkEl?.href || ''; + if (isVideo(href)) { + teardownRotation(); + const htmlLayer = containerEl.querySelector('.bp-html'); + const imgLayer = containerEl.querySelector('.bp-img'); + if (imgLayer) imgLayer.style.display = 'none'; + htmlLayer.innerHTML = ` + `; + return; + } + setupRotation(containerEl); + enhanceSVG(containerEl); + } }); - }); + }); }); }); } -function setupVideo(root=document){ - const links = root.querySelectorAll('a[href]'); - links.forEach(link=>{ - if(link.dataset.videoProcessed) return; + // Replaces plain video links with inline