Skip to content

Instantly share code, notes, and snippets.

View TheMasterR's full-sized avatar
🏠
Working from home

Lucian Pantea TheMasterR

🏠
Working from home
View GitHub Profile
@TheMasterR
TheMasterR / cfd-termux.sh
Created April 17, 2024 13:01 — forked from Erisa/cfd-termux.sh
Install the Cloudflare Daemon (cloudflared) in Termux
#!/bin/sh
echo 'NOTE: You can now install cloudflared directly from Termux repos.'
echo 'NOTE: To install it from source instead, open the script and comment out the next two lines.'
pkg install cloudflared
exit
# ^ comment out these lines to proceed with the script
echo "--upgrading packages"
yes "" | pkg update
@TheMasterR
TheMasterR / ArchLinuxWSL2.md
Created June 15, 2023 14:05 — forked from ld100/ArchLinuxWSL2.md
Steps for setting up Arch Linux on WSL2

Migrating from Ubuntu on WSL to ArchLinux on WSL2

Obsolete notice

This document was created back in 2020 and might not be actual nowadays. It is not supported anymore, so use thise information at your own risk.

Upgrading to WSL 2

  • Download WSL2 Kernel
  • run wsl --set-default-version 2 in windows command line, so that all future WSL machine will use WSL2.
@TheMasterR
TheMasterR / change-codec.md
Created November 29, 2022 09:38 — forked from dvf/change-codec.md
Enable High Quality mode on your headphones (Updated for macOS Catalina)

If you're using a high-end bluetooth headset on your Macbook Pro it's likely your mac is using an audio codec which favors battery efficiency over high quality. This results in a drastic degradation of sound, the SBC codec is the likely culprit, read more about it here.

Find out what codec you're using

  1. Play a song on your headphones
  2. Option (⌥) click the Bluetooth button at the top of your screen Inspect the Bluetooth Coded
  3. If you're using AAC or aptX, you can stop here—those are the highest quality codecs.

Change your codec to AAC or aptX

@TheMasterR
TheMasterR / Jest_GitLab_CI.md
Created March 4, 2022 15:11 — forked from rishitells/Jest_GitLab_CI.md
Setting up Jest tests and coverage in GitLab CI

Configuring Jest Tests in GitLab CI

1. Add GitLab CI configuration file in the root

In the root of your project, add .gitlab-ci.yml with the configuration below.

image: node:latest

stages:
@TheMasterR
TheMasterR / after.ts
Created October 9, 2021 05:32 — forked from metral/after.ts
// Define the application configuration and secrets.
const configs = new kx.ConfigMap("app-config", {
data: { "config": "very important data" }
});
const secrets = new kx.Secret("app-secrets", {
stringData: {
"app-password": new kx.RandomPassword("app-password"),
"database-password": config.databasePassword
}
@TheMasterR
TheMasterR / after.ts
Created October 9, 2021 05:32 — forked from metral/after.ts
// Define the application configuration and secrets.
const configs = new kx.ConfigMap("app-config", {
data: { "config": "very important data" }
});
const secrets = new kx.Secret("app-secrets", {
stringData: {
"app-password": new kx.RandomPassword("app-password"),
"database-password": config.databasePassword
}
@TheMasterR
TheMasterR / pulumiWaitFor.ts
Created October 9, 2021 05:32 — forked from metral/pulumiWaitFor.ts
Wait for a resource in pulumi
// Make sure x is a true output so pulumi doesn't try to run this function during preview.
const ingressIP = pulumi.all([x]).apply(async ([x]) => {
const kc = new k8sClient.KubeConfig();
const provider = (this.getProvider('kubernetes::') as any)
const kubeConfig = provider.kubeconfig as pulumi.Output<string>;
const ip = kubeConfig.apply(async (config) => {
kc.loadFromString(config);
const k8sApi = kc.makeApiClient(k8sClient.CoreV1Api);
@TheMasterR
TheMasterR / index.ts
Created October 9, 2021 05:31 — forked from metral/index.ts
private EKS cluster with public LB
import * as awsx from "@pulumi/awsx";
import * as eks from "@pulumi/eks";
import * as k8s from "@pulumi/kubernetes";
const name = "test001"
// Pull in existing VPC
const vpc = awsx.Network.fromVpc(name,
{
vpcId: "vpc-<ID0>",
@TheMasterR
TheMasterR / git-commit-log-stats.md
Created February 22, 2021 10:38 — forked from eyecatchup/git-commit-log-stats.md
Some commands to get git commit log statistics for a repository on the command line.

git commit stats

Commands to get commit statistics for a Git repository from the command line -
using git log, git shortlog and friends.




@TheMasterR
TheMasterR / index.js
Created August 15, 2020 17:54 — forked from msojda/index.js
Giphy chat bot
const express = require("express");
const app = express();
const PORT = process.env.PORT || 3000;
const bodyParser = require("body-parser");
const fetch = require("node-fetch");
app.use(bodyParser.json());
app.get("/", (req, res) => {
res.send("Hello World");
});