This is a sample script for highlighting the row and column of the selected cell using Google Apps Script. For this, the OnSelectionChange event trigger is used.
This file contains 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 logging | |
import os | |
import subprocess | |
import sys | |
import time | |
import urllib | |
from logging import getLogger | |
from dotenv import load_dotenv |
This file contains 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> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0"> | |
<title>Test Page</title> | |
<script> | |
// early compute the vw/vh units more reliably than CSS does itself | |
computeViewportDimensions(); |
This file contains 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 {chromium as browser, ElementHandle, Page} from "playwright"; | |
import {default as PQueue} from "p-queue" | |
const username: string = 'gander' | |
const links = new Set; | |
let nextPage: string = ''; | |
(async () => { | |
const pages = new PQueue({concurrency: 7}) |
This file contains 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
# the IP(s) on which your node server is running. I chose port 3000. | |
upstream app_geoforce { | |
server 127.0.0.1:3000; | |
} | |
upstream app_pcodes{ | |
server 127.0.0.1:3001; | |
} |
This file contains 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
# WSL2 network port forwarding script v1 | |
# for enable script, 'Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope CurrentUser' in Powershell, | |
# for delete exist rules and ports use 'delete' as parameter, for show ports use 'list' as parameter. | |
# written by Daehyuk Ahn, Aug-1-2020 | |
# Display all portproxy information | |
If ($Args[0] -eq "list") { | |
netsh interface portproxy show v4tov4; | |
exit; | |
} |
This file contains 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
#!/bin/bash | |
# parameters | |
USERNAME="" | |
PASSWORD="fritzbox-password" | |
CERTPATH="/usr/syno/etc/certificate/system/default/" ##this is the default Path for Synology Cert | |
CERTPASSWORD="" | |
HOST=http://192.168.178.1 ## I use IP instead of fritz.box for synology updates | |
# make and secure a temporary file |
This file contains 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
// two examples | |
// simple | |
// and with search | |
<script type="application/ld+json">{ | |
"@context": "http://schema.org", | |
"@type": "WebSite", | |
"name": "My Website Name", | |
"url": "https://example.com", |
This is a sample script for parsing HTML using Google Apps Script. When HTML data is converted to Google Document, the HTML data can be parsed and be converted to Google Document. In this case, the paragraphs, lists and tables are included. From this situation, I thought that this situation can be used for parsing HTML using Google Apps Script. So I could came up with this method.
In the Sheet API, the HTML data can be put to the Spreadsheet with the PasteDataRequest. But unfortunately, in this case, I couldn't distinguish between the body and tables.
The flow of this method is as follows. In this sample script, the tables from HTML are retrieved.
This file contains 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
describe("Dashboard Page", async() => { | |
it("Login as Basic", async() => { | |
await page.goto(baseUrl, {waitUntil: "networkidle0"}) | |
await page.click(".login-btn") | |
await page.waitForSelector('app-login form > input:nth-child(2)') | |
await page.type('app-login form > input:nth-child(2)', process.env.USERNAME) | |
await page.type('app-login form > input:nth-child(4)', process.env.PASSWORD) | |
await page.click('app-login form > button') | |
await page.waitForSelector('div.content-container > swiper') | |
}) |
NewerOlder