- Erstelle ein neues Verzeichnis für dein Projekt.
- Navigiere in das Projektverzeichnis.
- Führe den Befehl npm init aus, um ein neues package.json-Datei zu erstellen.
Deine Aufgabe ist es, eine PDF-Datei zu öffnen, ihre Seiten zu extrahieren und jede Seite als separate PDF-Datei zu speichern. Verwende dazu Node.js. Du kannst eine externe Bibliothek wie pdf-lib nutzen, um die Verarbeitung von PDF-Dateien zu erleichtern.
Leg ein neues Node.js-Projekt an. Benutze die Kommandozeile, um ein Verzeichnis für dein Projekt zu erstellen und führe npm init -y
aus, um ein package.json-Datei zu erstellen.
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
helo client.mydomain.com | |
mail from:<[email protected]> | |
rcpt to:<[email protected]> | |
data | |
From: [email protected] | |
Subject: test mail from command line | |
this is test number 1 | |
sent from linux box | |
. |
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
git branch -vv | grep 'origin/.*: gone]' | awk '{print $1}' | xargs git branch -d | |
# for german cli use | |
git branch -vv | grep 'origin/.*: entfernt]' | awk '{print $1}' | xargs git branch -d |
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
# Copy local files and directories to remote | |
rsync -av /local/dir/ server:/remote/dir/ |
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
# Remove all docker images and containers | |
docker stop $(docker ps -a -q) && docker rm $(docker ps -a -q) && docker rmi $(docker images -q) | |
docker build -t friendlyname . # Create image using this directory's Dockerfile | |
docker run -p 4000:80 friendlyname # Run "friendlyname" mapping port 4000 to 80 | |
docker run -d -p 4000:80 friendlyname # Same thing, but in detached mode | |
docker ps # See a list of all running containers | |
docker stop <hash> # Gracefully stop the specified container | |
docker ps -a # See a list of all containers, even the ones not running | |
docker kill <hash> # Force shutdown of the specified container |
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
# Download directory via scp | |
scp -r <user>@<host>:/path/to/dir /path/to/target/destination |
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
# Remove all untagged docker images | |
docker rmi $(docker images -q -f "dangling=true") |
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
ssh <ssh-user>@<ssh-host> -L <local-port>:<remote-host>:<remote-port> -N |
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 | |
git remote update origin --prune |
NewerOlder