Skip to content

Instantly share code, notes, and snippets.

View jdecode's full-sized avatar
🦾
Automate and Chill

Jagdeep Singh Kalsi jdecode

🦾
Automate and Chill
View GitHub Profile
@jdecode
jdecode / docker-part-1-the-3-things.md
Last active August 7, 2021 07:44
Docker | Part 1 : The 3 things

Docker | Part 1 : The 3 steps

Who is this for

  • Developers who want to understand what the hell is learn Docker but not sure where to begin

Note : PHP is used in most examples/samples below, and you can replace that with any other language/runtime environment

Life without Docker (the 3 steps)

  1. Get a new system (Desktop/Laptop)
@jdecode
jdecode / postgres-estimated-row-count-of-all-tables.sql
Created April 25, 2021 13:48
Show estimated row count of all tables in Postgres
SELECT schemaname,relname,n_live_tup
FROM pg_stat_user_tables
ORDER BY n_live_tup DESC;
Company
- hasMany : User
- hasMany : Project
- name
- active
Project
- hasMany : Task
- hasMany : User
- belongsTo : Company
@jdecode
jdecode / laravel-I-have-come-to-bargain.md
Created October 30, 2020 18:36
Laravel, I've come to bargain...

I have been doing a lot of "pros-and-cons" stuff from a little over 2 years now - about using Laravel.

I made it a big deal (and I believe I regret it in a certain capacity).

It should not have been a big deal.

It is a just another framework.

Finally, I have caught up with my senses and I strongly believe that I was too arrogant or stupid to not go down the Laravel path.

@jdecode
jdecode / dockerfile-for-php80-rc2-mysql-postgres.md
Last active February 28, 2024 09:11
Dockerfile for PHP 8.0 RC2 with MySQL and Postgres support
@jdecode
jdecode / geartable-dev.md
Created September 27, 2020 18:05
Geartable development

Actual code has not started yet and I have been thinking about several ways to accompalish this:

  1. CakePHP, MySQL - No Vue/TailwindCSS/DynamoDB
  2. Slim(PHP), Postgres, Vue/TailwindCSS
  3. Slim(PHP), DynamoDB, Vue/Tailwindcss

Fastest one (for now) would be the first option - more experience, recently worked on this a lot

Taking specific notes from "Noter" development - more on this tomorrow

@jdecode
jdecode / geartable-ui-design.md
Created September 26, 2020 22:44
Geartable UI design

Idea is to have a UI (minimal)

That gets the job done (for now)

Using TailwindCSS (with Dark-mode support)

Configured in CakePHP (mono-repo setup)

Avoiding CORS (again, for now)

@jdecode
jdecode / geartable-db-design.md
Last active September 26, 2020 22:53
Geartable DB design

This gist is to jump to the DB designing (without explaining the "Why/How DynamoDB" part).

  1. ERD - Entity Relation Diagram
  2. Define the Access Patterns
  3. Design PK/SK
@jdecode
jdecode / how-to-setup-a-project-in-ucreate.md
Created September 24, 2020 08:52
How to setup a project in ucreate

These are notes (mostly in comments) about the steps that are taken while setting up a new project

  1. Create Slack channel (internal, for developers/ucreate team/integration of tools)
  2. Add team members, and introduce the team
  3. Add "Integrations Bot" user (the "bot" user that will have the permissions for :reviewee: notifications)
  4. Setup GitHub repos (multiple, in case of separate client/server setups), and add people to the repo
@jdecode
jdecode / how-to-learn-something-in-a-technical-space.md
Last active March 22, 2022 06:12
How to learn something new in a technical space

As a learning plan, for a time-bound target (weekly, monthly even yearly) following guidelines must be followed:

Start with Why

  • Explain "Why you are going to build" (whatever it is that you are going to build)

Now, "What"

  • A table of contents (granulated to a common sense level) of what are you going to do/learn/build
  • Expectations in terms of scale (keep it small) and timeline (keep it short) of the Demo/POC that you would be building. Couple of examples:
  • Slack OAuth2 login(small scale) in 2 days(short timeline)