Skip to content

Instantly share code, notes, and snippets.

View narayann7's full-sized avatar
πŸš€
Just Tinkering!!

Narayan narayann7

πŸš€
Just Tinkering!!
View GitHub Profile
@narayann7
narayann7 / multiple-ssh-keys-git.adoc
Created April 24, 2023 22:58 — forked from alejandro-martin/multiple-ssh-keys-git.adoc
Configure multiple SSH Keys for Git

Use Multiple SSH Keys for Git host websites (Github, Gitlab)

This is guide about how to configure multiple SSH keys for some Git host websites such as Github, Gitlab, among others.

Creating SSH keys

  1. Create SSH directory:

@narayann7
narayann7 / flutter_build_apk_and_send_it_slack_channel.md
Created April 22, 2023 17:46
github action script for building release apk and send it to slack channel
name: Flutter CI

on:
  push:
    branches:
      - main
  pull_request:
    branches:
 - main
@narayann7
narayann7 / Flutter_CI.md
Created April 22, 2023 17:38
flutter ci for building apk
name: Flutter CI

on:
  push:
    branches:
      - main

jobs:
 build:
@narayann7
narayann7 / create desktop icon.md
Last active March 25, 2023 12:01
create a desktop icon for ubuntu,fedora etc. when you have an appimage or terminal script

create a file ending with .desktop . config and add below text in the file

[Desktop Entry]  
Version=1.0  
Name=Name of the application  
Comment=text you want to show when hovering above the icon  
Exec=Path of the executable file %U  
Icon=Path of the image  
Terminal=false  
StartupWMClass=name of application 
@narayann7
narayann7 / git setup.md
Last active May 6, 2024 08:28
how to setup more than one github or gitlab account
  1. to generate a key
ssh-keygen -t ed25519 -C "[email protected]" -f ./key_name
  1. add the file in home/.shh/

  2. add this in .shh/config

  • feat – a new feature is introduced with the changes
  • fix – a bug fix has occurred
  • chore – changes that do not relate to a fix or feature and don't modify src or test files (for example updating dependencies)
  • refactor – refactored code that neither fixes a bug nor adds a feature
  • docs – updates to documentation such as a the README or other markdown files
  • style – changes that do not affect the meaning of the code, likely related to code formatting such as white-space, missing semi-colons, and so on.
  • test – including new or correcting previous tests
  • perf – performance improvements
  • ci – continuous integration related
  • build – changes that affect the build system or external dependencies
@narayann7
narayann7 / clean_code.md
Created January 22, 2023 17:46 — 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

@narayann7
narayann7 / ANSI.md
Created January 9, 2023 13:54 — forked from fnky/ANSI.md
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
  1. add below command in package.json
"homepage": "https://narayann7.github.io/app-name"

// url = https:// + <username> .github.io/ <app-name>
  1. install npm i gh-pages -D
  2. add below command in scripts in package.json
 "predeploy": "npm run build",
@narayann7
narayann7 / common-info.md
Created May 24, 2022 10:19
general information dump

header type

  var headers1 = {
    "Content-type": "application/json",
    "Accept": "application/json",
  };

http status codes

1-- Informational