Skip to content

Instantly share code, notes, and snippets.

@theCoderCat
theCoderCat / egpu.md
Created September 17, 2021 13:45 — forked from cliffom/egpu.md
macOS + Win10/bootcamp eGPU Findings
@theCoderCat
theCoderCat / Update All Submodules in Source Tree.md
Created January 5, 2021 01:53 — forked from youandhubris/Update All Submodules in Source Tree.md
Update all Submodules, using a Custom Action, in Source Tree

Update all Submodules, using a Custom Action, in Source Tree

  1. Go to Actions > Custom Actions > Edit > Add

  2. Menu Caption Update All Submodules

  3. Check Show Full Output

  4. Script to run /usr/bin/git

    If installed in default location

  5. Parameters submodule update --recursive --remote

const mix = require('laravel-mix');
require('laravel-mix-copy-watched');
mix.js('resources/js/app.js', 'public/js')
mix.js('resources/js/auth.js', 'public/js')
.sass('resources/sass/app.scss', 'public/css')
.copyDirectoryWatched('resources/images', 'public/images')
.copyDirectoryWatched('resources/fonts', 'public/fonts')
.options({
processCssUrls: false
{
"private": true,
"scripts": {
"dev": "npm run development",
"development": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
"watch": "npm run development -- --watch",
"watch-poll": "npm run watch -- --watch-poll",
"hot": "cross-env NODE_ENV=development node_modules/webpack-dev-server/bin/webpack-dev-server.js --inline --hot --disable-host-check --config=node_modules/laravel-mix/setup/webpack.config.js",
"prod": "npm run production",
"production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --no-progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js"
package main
import "fmt"
func main() {
fmt.Println(scan([]int{0, 1, 2, 1, 2, 1, 2, 1, 2, 1, 9}))
}
func scan(A []int) int {
n := len(A)
package main
import "fmt"
func main() {
slice1 := [][]int{
[]int{1, 1, 1, 6, 6, 6, 6, 5},
[]int{1, 1, 1, 6, 6, 4, 6, 5},
[]int{6, 6, 6, 6, 3, 4, 6, 5},
[]int{6, 2, 2, 6, 3, 3, 5, 5},
[
{
"name": "succube tentactrice",
"affect": "play immediately",
"type": "black",
"description_en": "Play immediately\nSteal one equipment card from any player.",
"description_ja": "引いたらその場で使う\nあなたが選んだプレイヤーから1枚武器道具カードを奪う",
"description_fr": "A jouer immediatement\nVolez une carte equipement au joueur de votre choix."
},
{
// challenge detail: https://thecodercat.com/notes/read/hennge.md
package main
import (
"bufio"
"errors"
"fmt"
"os"
"strconv"

Access macOS localhost from IE or Edge within Parallels Desktop

This issue is so infuriating that I'm going to take some time to write about it.

  1. MOST IMPORTANT. Your local development server must be bound to IP address 0.0.0.0. Some do this by default, but many don't. You need to make sure that you run your local server with correct IP bindings. You may need to provide additional flags to your serve commands e.g. polymer serve --hostname domain.local, hugo serve --bind 0.0.0.0. If you use a named domain like domain.local, it has to be defined in /etc/hosts and pointing at 0.0.0.0.

  2. My Parallels setting is using Shared Network, nothing special there.

  3. Open macOS Terminal and type ifconfig. Look for the value under vnic0 > inet. It is typically 10.211.55.2.

sudo apt-get update
sudo apt-get install python3-pip python3-dev libpq-dev postgresql postgresql-contrib nginx
sudo -u postgres psql
- paste this code in postgres console:
CREATE DATABASE django_project;
CREATE USER username WITH PASSWORD 'pass1234';
ALTER ROLE username SET client_encoding TO 'utf8';
ALTER ROLE username SET default_transaction_isolation TO 'read committed';