Skip to content

Instantly share code, notes, and snippets.

View thepatrickniyo's full-sized avatar
:octocat:
Building & Mentoring

Patrick Niyogitare thepatrickniyo

:octocat:
Building & Mentoring
View GitHub Profile
Fetch 1
2025-04-14 15:20:28.763 DEBUG 536 --- [nio-8051-exec-1] org.hibernate.SQL :
select
business0_.id as id1_46_0_,
business0_.created_at as created_2_46_0_,
business0_.created_by_audit as created_3_46_0_,
business0_.created_date as created_4_46_0_,
business0_.last_modified_by as last_mod5_46_0_,
business0_.last_modified_date as last_mod6_46_0_,
business0_.state as state7_46_0_,
// Postman Test Script for Automatic Token Decryption
// Add this script to the "Tests" tab in your Postman request
// Configuration - Change this to match your secret key
const secretKey = "SECRET_KEY";
// Parse the response body
const responseBody = pm.response.json();
let decryptedData = null;
/**
* Prints text with support for bold sections (marked with **) and automatic line breaks
* @param {object} doc - The PDF document object
* @param {number} startY - The starting Y position
* @param {string} text - The input text with ** marking bold sections
* @param {object} options - Additional options for formatting
* @param {number} options.pageMargin - Page margin (default: 40)
* @param {number} options.innerPadding - Inner padding (default: 10)
* @param {number} options.lineSpacing - Spacing between lines (default: 10)
* @param {number} options.fontSize - Font size (default: 10)
Table User {
Id uuid [pk]
FirstName varchar
LastName varchar
Email varchar
Phone varchar
Password varchar
Role Role
Status UserStatus
CreatedAt datetime [default: `now()`]
import { createAsyncThunk, createSlice } from '@reduxjs/toolkit'
import type { RootState } from 'src/store/store'
import { SuccessListAPIResponse } from 'src/types/api-response';
import { MessageCategory } from 'src/types/category';
import { msgCategoriesService } from '@services/msg-categories.service';

// declaring the types for our state
export type MsgCategoriesState = {
    categories: Array<MessageCategory>,
import axios from 'axios';
import {IResponse} from '@interfaces/IResponse';

const upload = async (file: File): Promise<IResponse> => {
    const UPLOAD_PRESET: string = (import.meta.env.VITE_CLOUDINARY_UNSIGNED_UPLOAD_PRESET as string);
    const CLOUDINARY_NAME: string = (import.meta.env.VITE_CLOUDINARY_CLOUDNAME as string);
    const CLOUDINARY_API_KEY: string = (import.meta.env.VITE_CLOUDINARY_API_KEY as string);
    const CLOUDINARY_SECRET: string = (import.meta.env.VITE_CLOUDINARY_SECRET as string);
    const CLOUDINARY_IMAGES_FOLDER: string = (import.meta.env.VITE_CLOUDINARY_IMAGES_FOLDER as string);
@thepatrickniyo
thepatrickniyo / gist:992a3b705d8b0b26d97d9781d03767c9
Created September 28, 2022 18:08 — forked from rxaviers/gist:7360908
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: ๐Ÿ˜„ :smile: ๐Ÿ˜† :laughing:
๐Ÿ˜Š :blush: ๐Ÿ˜ƒ :smiley: โ˜บ๏ธ :relaxed:
๐Ÿ˜ :smirk: ๐Ÿ˜ :heart_eyes: ๐Ÿ˜˜ :kissing_heart:
๐Ÿ˜š :kissing_closed_eyes: ๐Ÿ˜ณ :flushed: ๐Ÿ˜Œ :relieved:
๐Ÿ˜† :satisfied: ๐Ÿ˜ :grin: ๐Ÿ˜‰ :wink:
๐Ÿ˜œ :stuck_out_tongue_winking_eye: ๐Ÿ˜ :stuck_out_tongue_closed_eyes: ๐Ÿ˜€ :grinning:
๐Ÿ˜— :kissing: ๐Ÿ˜™ :kissing_smiling_eyes: ๐Ÿ˜› :stuck_out_tongue:

Resolving Password authentication is temporarily disabled as part of a brownout. Please use a personal access token instead.

If you're trying to run git push origin main or basically accessing your remote git and you get the bellow error this blog is for you to get it resolved

error

remote: Password authentication is temporarily disabled as part of a brownout. Please use a personal access token instead.

remote: Please see https://github.blog/2020-07-30-token-authentication-requirements-for-api-and-git-operations/ for more information.
@thepatrickniyo
thepatrickniyo / clean_code.md
Created April 26, 2021 05:42 — forked from wojteklu/clean_code.md
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily โ€“ by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules