Skip to content

Instantly share code, notes, and snippets.

View rsrini7's full-sized avatar
😃
Happy

Srinivasan Ragothaman rsrini7

😃
Happy
View GitHub Profile
@rsrini7
rsrini7 / Main.java
Created May 28, 2022 06:52 — forked from kostanovych/Main.java
Simple example of compressing HTTP request via gzip with using Spring RestTemplate
import org.springframework.http.HttpMethod;
import org.springframework.http.client.ClientHttpRequest;
import org.springframework.http.client.SimpleClientHttpRequestFactory;
import org.springframework.web.client.HttpMessageConverterExtractor;
import org.springframework.web.client.RequestCallback;
import org.springframework.web.client.ResponseExtractor;
import org.springframework.web.client.RestTemplate;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
@rsrini7
rsrini7 / QEMU_ON_M1.md
Created November 21, 2021 10:28 — forked from citruz/QEMU_ON_M1.md
Create Ubuntu and Windows VMs with QEMU on Apple Silicon

Running Linux and Windows on M1 with QEMU

30.11.2020: Updated with the new patchseries and instructions for Windows

02.12.2020: Added tweaks

08.12.2020: Updated with patchseries v4

31.01.2020: Updated with patchseries v6

@rsrini7
rsrini7 / rm-docker.ps1
Created July 4, 2021 14:14 — forked from Instagit/rm-docker.ps1
Remove Docker for Windows
$ErrorActionPreference = "SilentlyContinue"
# stop Docker processes
kill -force -processname 'Docker for Windows', com.docker.db, vpnkit, com.docker.proxy, com.docker.9pdb, moby-diag-dl, dockerd
# kill MobyLinux
try {
./MobyLinux.ps1 -Destroy
} Catch {}
@rsrini7
rsrini7 / python_setuptools.md
Created May 30, 2021 04:52 — forked from CMCDragonkai/python_setuptools.md
Python Setuptools (Packaging Guidelines) #python

Python Setuptools

Python setuptools package replaces the distutils package. You use this in order to allow your Python package to be redistributable. Not just for PyPi but also for source distributions or private distributions.

First you need a setup.py at your project root:

@rsrini7
rsrini7 / gist:b5efc340024f1128e52a641959439852
Created December 6, 2020 12:13 — forked from adhorn/gist:c315cb13331528b09f39a592344ec7cb
Chaos Toolkit experiment to stop docker locally
{
"version": "1.0.0",
"title": "What is the impact of an terminating the database master",
"description": "terminating the master database should not prevent the application from running",
"tags": ["db"],
"configuration": {
"endpoint_url": {
"type": "env",
"key": "ELEANOR_URL"
}
@rsrini7
rsrini7 / tflite_sinewave_training.ipynb
Created June 3, 2020 18:14 — forked from ShawnHymel/tflite_sinewave_training.ipynb
TensorFlow Lite Sinewave Regression Training and Conversion
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@rsrini7
rsrini7 / aliasrc
Last active January 11, 2020 11:50 — forked from LukeSmithxyz/zshrc
#!/bin/sh
# Use neovim for vim if present.
command -v nvim >/dev/null && alias vim="nvim" vimdiff="nvim -d"
# Verbosity and settings that you pretty much just always are going to want.
alias \
cp="cp -iv" \
mv="mv -iv" \
rm="rm -v" \
@rsrini7
rsrini7 / gitfolders.py
Last active December 18, 2021 04:36 — forked from nkmathew/gitfolders.py
Backup those reference projects gitfolders
#!/usr/bin/env python
r"""
Author: nkmathew <kipkoechmathew@gmail.com>, Srini
Date: April 29, 2016
Date: Sept 12, 2019
The script generates a list of all the reference git repos in a certain folder and
its subfolders should you need to reclone them later in the same structure
@rsrini7
rsrini7 / add_mingw64.reg
Created July 13, 2019 13:43 — forked from a358003542/add_mingw64.reg
quickly open your cmd in windows or quickly open your msys2 or mingw64 cmd window.
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Directory\Background\shell\open_mingw64]
@="Open MINGW64 here"
[HKEY_CLASSES_ROOT\Directory\Background\shell\open_mingw64\command]
@="c:\\msys64\\msys2_shell.cmd -mingw64 -here"
@rsrini7
rsrini7 / add-open-cmd-and-powershell-here.reg
Created July 13, 2019 13:26 — forked from BekirUzun/add-open-cmd-and-powershell-here.reg
Add open command window here and powershell here
Windows Registry Editor Version 5.00
; Add Open cmd and powershell here with administrator variations to right click context menu
[HKEY_CLASSES_ROOT\Directory\Background\shell\CliHere]
"MUIVerb"="Open CLI here"
"Position"="Middle"
"Icon"="cmd.exe"
"SubCommands"=""