This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Function Analysis() { | |
echo "Analysis ver. 1" | |
date | |
Get-ComputerInfo | Out-String | |
echo "==========" | |
echo "the contents of hosts file:" | |
cat C:\Windows\system32\drivers\etc\hosts | |
echo "==========" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
while :; do | |
if ifconfig | grep -q ipsec0; then | |
osascript -e 'tell application "System Events" to tell appearance preferences to set dark mode to true' | |
else | |
osascript -e 'tell application "System Events" to tell appearance preferences to set dark mode to false' | |
fi | |
sleep 5 | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl -sSO https://dl.google.com/cloudagents/add-monitoring-agent-repo.sh | |
sudo bash add-monitoring-agent-repo.sh | |
sudo apt-get update | |
sudo apt-cache madison stackdriver-agent | |
sudo apt-get install -y 'stackdriver-agent=6.*' | |
sudo service stackdriver-agent start | |
sudo systemctl enable stackdriver-agent |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import os | |
import re | |
import sys | |
with open(sys.argv[1]) as fp: | |
obj = json.load(fp) | |
dir = f'{obj["name"]}' | |
os.makedirs(dir, exist_ok=True) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sub saveSheetsAsCSV() | |
Dim i As Integer | |
Dim fName As String | |
Application.DisplayAlerts = False | |
For i = 1 To Worksheets.Count | |
fName = "C:\Users\yk\Downloads\sheet-" & i & ".csv" | |
ActiveWorkbook.Worksheets(i).SaveAs Filename:=fName, FileFormat:=xlCSVUTF8 | |
Next i | |
End Sub |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import admin from 'firebase-admin'; | |
admin.initializeApp(); | |
function listAllUsers(nextPageToken?: any) { | |
// List batch of users, 1000 at a time. | |
admin | |
.auth() | |
.listUsers(10, nextPageToken) | |
.then(function(listUsersResult) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get update | |
sudo apt-get install \ | |
apt-transport-https \ | |
ca-certificates \ | |
curl \ | |
gnupg-agent \ | |
software-properties-common | |
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo apt-key add - | |
sudo add-apt-repository \ | |
"deb [arch=amd64] https://download.docker.com/linux/debian \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<div> | |
{{ x }} | |
</div> | |
</template> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Windows Registry Editor Version 5.00 | |
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout] | |
"Scancode Map"=hex:00,00,00,00,00,00,00,00,03,00,00,00,1d,00,3a,00,59,00,70,00,\ | |
00,00,00,00 | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html> | |
<head> | |
<style> | |
* { | |
box-sizing: border-box; | |
} |