Steps to deploy Node.js to VPS using PM2 and Github Actions
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
# A basic script for uninstalling app packages in Windows 10/11, including those pre-installed with Windows | |
# | |
# Note: If you get an error about the script not being allowed to run, the below command will change the execution polciy temporarily for one session only: | |
# Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope Process | |
# | |
# To execute the script, open a Powershell window to the directory with the script and run the following command using your scripts file name (and don't forget the .\ ) | |
# .\WhateverScriptName.ps1 | |
# ------------------------------------------------------------------------------------------- | |
# Script by ThioJoe - https://github.com/ThioJoe | |
We can't make this file beautiful and searchable because it's too large.
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
Twitter ID, Screen name, Followers | |
12,jack,6526006 | |
13,biz,2608289 | |
20,ev,1679155 | |
57,SarahM,17448 | |
59,Tim535353,9340 | |
76,marciadorsey,19501 | |
224,davepell,57523 | |
291,goldman,916937 | |
295,joshk,149086 |
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 {OAuth2User, OAuth2UserOptions} from "twitter-api-sdk/dist/OAuth2User.js"; | |
export default class TwitterOauthService extends OAuth2User { | |
#options: OAuth2UserOptions | |
#code_verifier?: string | |
#code_challenge?: string | |
/** | |
* Modified so that codeVerifier and codeChallenge can be set in the constructor. | |
* Also, codeVerifier and codeChallenge need to be saved in cookies etc., so I made a getter. |
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
// ==UserScript== | |
// @name TweetDeck Cramming | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description Allow 280 characters in a Tweet sent from TweetDeck automatically | |
// @author Erydactyl and Zemnmez | |
// @run-at document-idle | |
// @match https://tweetdeck.twitter.com/* | |
// @grant * | |
// ==/UserScript== |
Past August 2024, Authy stopped supported the desktop version of their apps:
See Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August for details.
And indeed, after a while, Authy changed something in their backend which now prevents the old desktop app from logging in. If you are already logged in, then you are in luck, and you can follow the instructions below to export to tokens.
If you are not logged in anymore, but can find a backup of the necessary files, then restore those files, and re-install Authy 2.2.3 following the instructions below, and it should work as expected.
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
const axios = require('axios'); | |
const http = require('http'); | |
const https = require('https'); | |
module.exports = axios.create({ | |
//60 sec timeout | |
timeout: 60000, | |
//keepAlive pools and reuses TCP connections, so it's faster | |
httpAgent: new http.Agent({ keepAlive: true }), |
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
axios({ | |
url: 'http://localhost:5000/static/example.pdf', | |
method: 'GET', | |
responseType: 'blob', // important | |
}).then((response) => { | |
const url = window.URL.createObjectURL(new Blob([response.data])); | |
const link = document.createElement('a'); | |
link.href = url; | |
link.setAttribute('download', 'file.pdf'); | |
document.body.appendChild(link); |
NewerOlder