Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
In The Cloud

HoLengZai

💭
In The Cloud
View GitHub Profile
@HoLengZai
HoLengZai / popimap.sh
Created Jul 29, 2021 — forked from jay0lee/popimap.sh
Shell script that can do OAuth, domain-wide delegation or password based IMAP/POP/SMTP authentication
View popimap.sh
#!/bin/bash
#
# This script should be run from Linux and uses basic tools like grep, awk, date and openssl.
# You need to populate the client_id and client_secret variables below
# with your own GCP project values. Sample command lines:
#
# Use 3-legged IMAP OAuth (default):
# bash popimap.sh --email myaccount@example.com --protocol imap
#
# Use a service account and domain-wide delegation:
View Backup-AzureDevOPS_Instance.ps1
#Please refer to the Microsoft Docs website to get your PAT (Personal Access Tokens)
#https://docs.microsoft.com/en-us/azure/devops/organizations/accounts/use-personal-access-tokens-to-authenticate?view=azure-devops
param
(
[Parameter(Mandatory = $true)]
[string]$pat,
[Parameter(Mandatory = $true)]
[string]$instance,
@HoLengZai
HoLengZai / whynot.py
Created Mar 15, 2018 — forked from futurepaul/whynot.py
The “Why’d you push that button” button
View whynot.py
#Step 1: Import the libraries we need
import pygame.mixer
import RPi.GPIO as GPIO
import glob
import random
import time
#Step 2: Fire up the sound mixer
pygame.mixer.init()