Find where container's logs are:
docker inspect --format='{{.LogPath}}' <container_name>
REM usage: killport.bat <port> | |
@echo off | |
setlocal | |
echo Killing port %1 | |
for /f "tokens=5" %%a in ('netstat -ano ^| findstr ":%1"') do taskkill /f /pid %%a |
Find where container's logs are:
docker inspect --format='{{.LogPath}}' <container_name>
function dotenv() { | |
file=${1-".env"} | |
set -a; source $file; set +a | |
} |
{ | |
"window.zoomLevel": 0, | |
"editor.tabSize": 2, | |
"editor.detectIndentation": false, | |
"editor.insertSpaces": true, | |
"editor.renderWhitespace": "boundary", | |
"workbench.panel.defaultLocation": "bottom", | |
"editor.fontFamily": "'Fira Code', Menlo, Monaco, 'Courier New', monospace", | |
"editor.fontLigatures": true, | |
// "editor.formatOnSave": true, |
#!/bin/bash | |
DOCKERFILE=Dockerfile.dev | |
build_image() { | |
# Uncomment if you don't want to build an image if it already exists | |
#if [ ! "$(docker image ls | grep $1)" ]; then | |
echo "Build" | |
docker build . -t $1 -f $DOCKERFILE | |
#fi |
@echo off | |
for /f "delims=" %%a in ('git describe --tags --abbrev^=0') do @set latesttag=%%a | |
git log %latesttag%..HEAD --graph --oneline |
route -n get default | grep interface | awk '{ print $2 }' | xargs ipconfig getifaddr |
git log --pretty=format:'%C(yellow)%h %Cred%ad %Cblue%an%Cgreen%d %Creset%s' |
docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $1 |
#!/bin/bash | |
# Usage: heroku_dotenv.sh <heroku_app_name> <dotenv_file> | |
# Default dotenv_file: .env | |
dotenv=${2-".env"} | |
heroku config -a $1 | | |
sed -n '1!p' | | |
awk '{ gsub(/:/,"", $1); f=$1; $1=""; print f"="substr($0,2) }' > $dotenv | |
cat $dotenv | |
echo "File written: $dotenv" |