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
#!/bin/bash | |
wget -O pgsql.zip "https://sbp.enterprisedb.com/getfile.jsp?fileid=1258319" | |
unzip -dpgsql_binaries pgsql.zip | |
rm pgsql.zip | |
cd pgsql_binaries | |
xattr -d com.apple.quarantine ./bin/* | |
xattr -d com.apple.quarantine ./lib/* | |
xattr -d com.apple.quarantine ./lib/postgresql/* | |
./bin/initdb -D ./pgdata -U postgres -W -E UTF8 -A scram-sha-256 |
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 getBrackets(str) { | |
// Initialize the stack to keep track of open braces | |
const stack = []; | |
// Initialize the result string | |
let result = ""; | |
// Iterate over each character in the input string | |
for (let i = 0; i < str.length; i++) { | |
const char = str[i]; |
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 React from 'react'; | |
import { useState } from 'react'; | |
import { makeStyles } from '@material-ui/core/styles'; | |
import Paper from '@material-ui/core/Paper'; | |
import Grid from '@material-ui/core/Grid'; | |
import Box from '@material-ui/core/Box'; | |
import Divider from '@material-ui/core/Divider'; | |
import TextField from '@material-ui/core/TextField'; | |
import Typography from '@material-ui/core/Typography'; | |
import List from '@material-ui/core/List'; |
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
Line 1305 in wp-includes/pluggable.php you can find; | |
function wp_redirect( $location, $status = 302, $x_redirect_by = 'WordPress' ) { | |
that is probably what executes the redirect, so just add a | |
die($location); | |
to see if this is indeed the culprit. |
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
setInterval(()=> { | |
document.getElementsByClassName('star-ratings')[0]?.style?.display = 'none'; | |
document.getElementsByClassName('star')[4]?.parentElement?.parentElement?.click() | |
}, 100) |
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 React, { createRef } from "react"; | |
import ReactDOM from "react-dom"; | |
export default class Frame extends React.Component { | |
constructor(props) { | |
super(props) | |
this.ref = createRef() | |
} | |
render() { | |
return <iframe ref={this.ref}></iframe> |
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 { accessSync, promises as fs } from 'fs'; | |
(async()=>{ | |
const input = await fs.readFile("./interpretertests/aoc_21_13_input.txt", 'utf8') | |
const p = (grid) => { | |
for (let y = 0; y < grid.length; y++) { | |
console.log(grid[y].map(x=>x==0?'.':'#').join('')) |
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 { accessSync, promises as fs } from 'fs'; | |
(async()=>{ | |
const input = await fs.readFile("./interpretertests/aoc_21_7_input.txt", 'utf8') | |
const positions = input.split('\n')[0].split(',').map(Number) | |
const max = Math.max(...positions) |
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 { timeStamp } from 'console'; | |
import { accessSync, promises as fs } from 'fs'; | |
(async()=>{ | |
const input = await fs.readFile("./interpretertests/aoc_21_6_input.txt", 'utf8') | |
const f = (days) => { | |
const timers = input.split(',').map(Number) | |
let days8 = timers.map(t=>[1, t]) |
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 { accessSync, promises as fs } from 'fs'; | |
(async()=>{ | |
const input = await fs.readFile("./interpretertests/aoc_21_2_input.txt", 'utf8') | |
const result = input.split('\n').reduce((acc, line) => { | |
let [cmd, i] = line.split(' ') | |
i = parseInt(i) | |
switch(cmd) { |