Skip to content

Instantly share code, notes, and snippets.

View cr-solutions's full-sized avatar

Ricardo Cescon cr-solutions

View GitHub Profile

An guide how to activate Windows 11 Pro for free

Why?

Because you will get some more features like an Bitlocker and host your device as an External Desktop which can be accessed through the internet

Am i also able to switch from any other edition to Pro?

The answer is yes! You can switch from almost any edition to Pro completely for free!

Note for users with unactivated Pro edition

People which already have Pro, but not activated, can skip to this step.

Getting started

What you first need to do is open CMD (Command Prompt) as Administrator using this keyboard key:

@midom
midom / topwaits.py
Created July 2, 2020 17:11
stall detector!
#!/usr/bin/env bcc-py
#
# topwaits Show longest off-cpu waits per-stack
#
# Copyright 2019 Facebook, Inc.
# Copyright 2016 Netflix, Inc.
# Licensed under the Apache License, Version 2.0 (the "License")
#
# 13-Jan-2016 Brendan Gregg Wrote offcpu profiler
# 27-Nov-2019 Domas Mituzas Gutted most of profiling part and left stall detector
@bradennapier
bradennapier / recursive-install.js
Last active December 7, 2023 15:44
Recursively find and install dependencies in subdirectories
const path = require('path');
const { promises: fs } = require('fs');
const cp = require('child_process');
/*
Recursively iterates and finds subdirectories which have a `package.json` file and does a dependency installation based
on the given configuration.
- can be setup to use yarn or npm
- can be setup to determine the command to use based on lock files so that if you set it to use yarn but a directory only
@lamak-qaizar
lamak-qaizar / redis-slowlog-pretty-printer.py
Last active November 27, 2020 07:47
Redis SLOWLOG pretty printer with formatted timestamps
# 1. Requirements:
# python3.6, redis-py
# 2. Run instructions:
# python redis-slowlog-pretty-printer.py <redis endpoint> <port> <# logs to get>
# eg. python redis-slowlog-pretty-printer.py localhost 6379 10
# 3. Sample output:
# <local date/time> [ <execution time> ]: <command>
# 2017-06-22 00:00:00 [ 10.0 s ]: b'keys *rk54jhk345hnmmlk4lk*'
@corbanb
corbanb / pre-request-jwt.js
Last active July 22, 2024 13:12
JWT tokenize - Postman Pre-Request Script
function base64url(source) {
// Encode in classical base64
encodedSource = CryptoJS.enc.Base64.stringify(source);
// Remove padding equal characters
encodedSource = encodedSource.replace(/=+$/, '');
// Replace characters according to base64url specifications
encodedSource = encodedSource.replace(/\+/g, '-');
encodedSource = encodedSource.replace(/\//g, '_');
@csonuryilmaz
csonuryilmaz / clone-mysql-db.sh
Last active May 17, 2024 12:12 — forked from christopher-hopper/clone-mysql-db.sh
Clone a MySQL database to a new database on the same server without using a dump file. This is much faster than using mysqldump.
#!/bin/bash
DBUSER="root";
DBPASS="";
DBHOST="localhost";
DB_OLD=mydatabase
DB_NEW=clone_mydatabase
DBCONN="--host=${DBHOST} --user=${DBUSER} --password=${DBPASS}";
@ziadoz
ziadoz / install.sh
Last active November 7, 2024 19:48
Install Chrome, ChromeDriver and Selenium on Ubuntu 16.04
#!/usr/bin/env bash
# https://developers.supportbee.com/blog/setting-up-cucumber-to-run-with-Chrome-on-Linux/
# https://gist.github.com/curtismcmullan/7be1a8c1c841a9d8db2c
# https://stackoverflow.com/questions/10792403/how-do-i-get-chrome-working-with-selenium-using-php-webdriver
# https://stackoverflow.com/questions/26133486/how-to-specify-binary-path-for-remote-chromedriver-in-codeception
# https://stackoverflow.com/questions/40262682/how-to-run-selenium-3-x-with-chrome-driver-through-terminal
# https://askubuntu.com/questions/760085/how-do-you-install-google-chrome-on-ubuntu-16-04
# Versions
CHROME_DRIVER_VERSION=`curl -sS https://chromedriver.storage.googleapis.com/LATEST_RELEASE`
@adamreisnz
adamreisnz / package.json
Last active August 22, 2024 10:12
Simple pure npm scripts build process
{
"name": "project-name",
"description": "Template for static sites",
"version": "1.0.0",
"homepage": "http://www.project-name.com",
"author": {
"name": "Adam Reis",
"url": "http://adam.reis.nz"
},
"license": "UNLICENSED",
@noelboss
noelboss / git-deployment.md
Last active October 12, 2024 16:09
Simple automated GIT Deployment using Hooks

Simple automated GIT Deployment using GIT Hooks

Here are the simple steps needed to create a deployment from your local GIT repository to a server based on this in-depth tutorial.

How it works

You are developing in a working-copy on your local machine, lets say on the master branch. Most of the time, people would push code to a remote server like github.com or gitlab.com and pull or export it to a production server. Or you use a service like deepl.io to act upon a Web-Hook that's triggered that service.

@samiraguiar
samiraguiar / MC Cheat Sheet
Last active November 10, 2024 16:02 — forked from maciakl/MC Cheat Sheet
Midnight Commander Cheat Sheet / Shortcuts
Note for newcomers:
In the shortcuts below, "C" stands for CTRL and "A" stands for "ALT". This is a convention
used in the Midnight Commander documentation and was kept here.
You can also use "ESC" instead of "ALT", which is useful on Macbooks.
Main View
---------------------------------------------------------------
- File/directory operations