Clean cargo projects

Quick clean all your cargo (Rust) projects in folder:

find * -maxdepth 1 -mindepth 1 -type d -execdir cargo clean ";"

Change JAVA_HOME in powershell

 $env:JAVA_HOME = 'C:\apps\liberica-jdk-11\'

Spaces between = is very importments.

Fixing archlinux pacman integerity errors

If you look something like :

error: freeplane: signature from "Leonidas Spyropoulos <>" is marginal trust
:: File /var/cache/pacman/pkg/freeplane-1.9.12-1-any.pkg.tar.zst is corrupted (invalid or corrupted package (PGP signature)).

You should update keys:

sudo pacman -Sy archlinux-keyring

plantuml all keywords

You can get all keywords from plantuml (include skin parameters):

java -Djava.awt.headless=true -jar plantuml.jar  -language

Groups of keywords:

  • type
  • keyword
  • preprocessor
  • skinparameter
  • color

Quick access to all skin parameters of sequence diagramm:

java -jar plantuml.1.2020.9.jar -language | grep "Sequence"

Flush running docker (podman) container

Quick flushing docker container.
Script for fish shell!. If you want to use it in bash, you should make slightly changes.

set ctrn_id (podman ps -a | grep couchbase | head -c 12) && podman rm $ctrn_id -fv

First or last symbols in string

Last 12 symbols from UUID:

uuidgen | tail -c 12

First 8 symbols from UUID:

uuidgen | head -c 8

Add user to group

sudo usermod -aG $GROUP $USER

Linux rescue

In grub menu select autoline and press e. Find the line which is started with linux and append


to the end of this. After you will boot it (Ctrl-x), you will get a root shell immediately. But the filesystme will be in the readonly mode. To fix it execute:

mount -o remount, rw /

How to send SOAP request with curl

curl -d @message.xml -H "Content-Type: text/xml; charset=utf-8"  "endpoint"


  • message.xml - a file with the SOAP request
  • endpoint - the URL of the web-service endpoint


rename "s/DCIM/2010/" *

This command replace DCIM to 2010 in names of all directorie's files.

Add user's rights in ACL

Add full permissions for a folder:

setfacl -Rm u:ubuntu:rwx /opt/folder

Full permissions for folder and new entities in folder:

setfacl -Rm d:u:ubuntu:rwx /opt/folder

Git Usefull comands

git clean -d -f [path]

Remove untracked files, that described in ignore lists. It's usefull if you switch between branches, which of them contains removed (and ignored) file, that exists in other.

Exclude file from resource in Gradle

If you want to exclude one file from resource, you may use this snippet:

sourceSets {
	main {
		resources {
			exclude '**/*.bak'

Gradle dependecies

To view dependencies hierarchy:
gradle dependencies