Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
| सत्यान्वेषी अनुसंधानकर्ता |

Abhijit Bose boseji

💭
| सत्यान्वेषी अनुसंधानकर्ता |
  • ऊँᳬ᳞ | सत्यान्वेषी अनुसंधानकर्ता |
  • Lab
View GitHub Profile
@boseji
boseji / pbkdf2-gen.go
Created May 10, 2021
PBKDF2 Key Derivation
View pbkdf2-gen.go
// Copyright 2021 Abhijit Bose. All rights reserved.
// Use of this source code is governed by a Apache 2.0 license
package main
import (
"bytes"
"crypto/rand"
"crypto/sha256"
"encoding/hex"
@boseji
boseji / bcrypt-gen.go
Created May 10, 2021
bcrypt for Passwords
View bcrypt-gen.go
// Copyright 2021 Abhijit Bose. All rights reserved.
// Use of this source code is governed by a Apache 2.0 license
package main
import (
"fmt"
"encoding/hex"
"golang.org/x/crypto/bcrypt"
)
View aes-gcm-decrypt.go
// Copyright 2021 Abhijit Bose. All rights reserved.
// Use of this source code is governed by a Apache 2.0 license
package main
import (
"crypto/aes"
"crypto/cipher"
"encoding/hex"
"fmt"
@boseji
boseji / workerpool1.go
Created May 10, 2021
Golang Simple Worker Pool Example
View workerpool1.go
// Copyright 2020 Abhijit Bose. All rights reserved.
// Use of this source code is governed by a Apache 2.0 license
package main
import (
"log"
"sync"
"time"
)
@boseji
boseji / Firebase-snippets.md
Last active Feb 1, 2020
Firebase Quick use snippets - some commands and some code to get started quickly
View Firebase-snippets.md

Firebase Snippets

This documents provides a brief command sequences and code that can get you started with [Google Firebase][1].

Install Command Line Tools

Firebase uses command line tools to perform upload, test and deploy actions.

@boseji
boseji / pypinit.sh
Last active Jan 9, 2020
Python Project Initialize script inspired by "Learn Python the Hard Way by Zed A Shaw"
View pypinit.sh
#!/bin/sh
###########################################
### Workspace Startup File
###
### @brief Creates the Required files and configuration needed
### to begin working with Python projects
### This work has been inspired by:
### Learn Python the Hard Way by Zed A Shaw
### - Great book on python and other topics
### - Visit: https://learnpythonthehardway.org/
@boseji
boseji / git-commit-email-modify.md
Created Aug 13, 2019
Rename the Commiter and Email address in Git
View git-commit-email-modify.md

Details

This command would alter the default committer name and email address for each of the commits.

This command uses the git filter-branch command.

$ git filter-branch --env-filter '
WRONG_EMAIL="wrong@example.com"
NEW_NAME="New Name Value"
@boseji
boseji / Manjaro-tricks.md
Last active Dec 1, 2020
Manjaro Linux : Tips and Tricks (ARCH Linux under the hood)
View Manjaro-tricks.md

Manjaro Linux : Tips and Tricks

We have been using [Manjaro linux][2] for past year and have been happy with its perfomance. Though we don't use te [AUR][1] (Arch User Repository, since many are not supported into Manjaro.

The best part is even with bad / dumb users like myself, IT-DOES-NOT-BREAK. So, we very much recommend [Manjaro][2].

It seriously worked much better than Ubuntu. We might not be able to have all the boat load of software & support like Debian, but we are happy.

View git-fetch-upstream-tags
Let [tag] = any tag in upstream repo
git fetch upstream --tags
git push origin --tags
@boseji
boseji / RTL8711_SPI-Flash-ID.ino
Created May 9, 2018
RTL8711 to SPI Flash connection and checking of Device Signature
View RTL8711_SPI-Flash-ID.ino
#include <SPI.h>
#include "PinNames.h"
// 11 - GPIOC_2 - SPI0_MOSI = Connected to Chip SPI MOSI
// 12 - GPIOC_3 - SPI0_MISO = Connected to Chip SPI MISO
// 13 - GPIOC_1 - SPI0_CLK = Connected to Chip SPI SCK
// GPIOC_4 - SPI0_CS1 = Connected to Chip SPI CS
#define CS PC_4
SPISettings settings = SPISettings(20000000, MSBFIRST, SPI_MODE0);
void setup() {