To install a custom package or modify an existing docker image we need to
- run a docker a container from the image we wish to modify
- modify the docker container
- commit the changes to the container as a docker image
- test changes made to image
#----------------------------------------------------------------------- | |
# To create the docker image : | |
# cd <this file directory> | |
# docker build -t apache-php-dev . | |
# | |
# Start image : | |
# docker run -d -p 80:80 -v /home/user/public_html:/var/www/html apache-php-dev | |
# | |
# Open browser : | |
# http://localhost |
To install a custom package or modify an existing docker image we need to
FROM php:5.6-apache | |
RUN apt-get update && apt-get install -y libpq-dev && docker-php-ext-install pdo pdo_pgsql | |
COPY src/ /var/www/html |
Lee Benfield's Java decompiler CFR is straight forward and can even batch decompile jar container.
cd /usr/local/bin && wget http://www.benf.org/other/cfr/cfr_0_115.jar
java -jar /usr/local/bin/cfr_0_115.jar javaclasstodecompiles.class
# Set the prefix to ^A. | |
unbind C-b | |
set -g prefix ^A | |
bind a send-prefix | |
# Start windows and panes at 1, not 0 | |
set -g base-index 1 | |
set -g pane-base-index 1 | |
set -g renumber-windows on |
//download pages that are referenced by a "a element", usefull for pages with links to documentations | |
Array.from(document.querySelectorAll('body > p > a')).map(x=>"wget "+x.href).join(" & "); |
#!/bin/bash | |
bash -c "$(curl -fsSL https://raw.githubusercontent.com/ohmybash/oh-my-bash/master/tools/install.sh)" && sed -i 's/SH_THEME="font"/SH_THEME="bobby"/' ~/.bashrc && exec bash |
Markdown Preview Enhanced supports rendering flow charts
, sequence diagrams
, mermaid
, PlantUML
, WaveDrom
, GraphViz
, Vega & Vega-lite
, Ditaa
diagrams.
You can also render TikZ
, Python Matplotlib
, Plotly
and all sorts of other graphs and diagrams by using Code Chunk.
Please note that some diagrams don't work well with file exports such as PDF, pandoc, etc.
This feature is powered by flowchart.js.
if [[ -z "$WORKSPACE_DIR" ]]; then | |
if [[ -d "/var/www/html" ]]; then | |
WORKSPACE_DIR='/var/www/html' | |
fi | |
fi | |
workspaces=$(echo "$WORKSPACE_DIR" | tr ':' ' ') #in case multiple projects open fast | |
#project=$(find $workspaces -maxdepth 1 -type d | fzf) | |
if [[ "$SHELL" =~ *zsh$ ]]; then |