This file contains 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
CHARINDEX('FDFF',CONVERT(varchar(max),(CAST(___COLUMN___ AS VARBINARY(max))),2)) > 0 |
This file contains 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
xxd -c 1 binary_file | sed 's/^[0-9a-z]*//' > binary_file.hex |
This file contains 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
#some grep pattern | |
pattern=192.168 | |
# save latest n images | |
n=1 | |
# check first (?): | |
# docker inspect -f '{{ .Created }} {{ .Id }} {{ .RepoTags }}' $(docker images | tail -n+2 | sed 's/^\([^ ]*\) *\([^ ]*\) *\([^ ]*\).*/ \1:\2 \3 /' | grep $pattern | cut -d' ' -f3) | sort -r | tail -n+$((n+1)) | |
docker rmi $(docker inspect -f '{{ .Created }} {{ .Id }}' $(docker images | tail -n+2 | sed 's/^\([^ ]*\) *\([^ ]*\) *\([^ ]*\).*/ \1:\2 \3 /' | grep $pattern | cut -d' ' -f3) | sort -r | tail -n+$((n+1)) | cut -d' ' -f2 | cut -c8-) |