- How To Ask Questions The Smart Way [link]
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 | |
# Stops and deletes ALL Docker resources | |
docker image prune | |
docker rmi $(docker images -a -q) | |
docker stop $(docker ps -a -q) | |
docker rm $(docker ps -a -q) | |
docker system prune -f | |
docker system prune -a | |
docker volume prune -f |
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
FROM node:20.15.3-alpine AS base | |
RUN mkdir -p /opt/app | |
WORKDIR /opt/app | |
RUN adduser -S user | |
RUN chown -R user /opt/app | |
COPY package*.json ./ | |
FROM base AS development | |
RUN npm install | |
COPY . ./ |
Highlighted block quotes for GitHub MD files
Reference: https://github.com/orgs/community/discussions/16925
> [!NOTE]
> Highlights information that users should take into account, even when skimming.
> [!TIP]
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 | |
# Prints the version of a nodejs package.json file | |
VERSION=`node -e "console.log(require('../app/package.json').version)"` | |
echo Synchronizing all modules to version $VERSION |
A list of interesting React optimization techniques.
[1] Do less work during rendering
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
:: Compact/compress the size of an Ubuntu VDI file on VirtualBox (v7.0) running in a Windows host | |
:: The VDI file should should have previously run "compact.sh" in the VM before running this script | |
:: Add VBoxManage.exe to the PATH variable to make it globally available. Usually it's in | |
:: C:\Program Files\Oracle\VirtualBox\VBoxManage.exe | |
VBoxManage.exe modifymedium --compact c:\path\to\thedisk.vdi |
NewerOlder