Skip to content

Commit

Permalink
notes
Browse files Browse the repository at this point in the history
  • Loading branch information
BostX committed Feb 16, 2024
1 parent ea2799f commit 6725069
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
13 changes: 12 additions & 1 deletion notes/cli/linux.scrbl
Original file line number Diff line number Diff line change
Expand Up @@ -1036,9 +1036,20 @@
# :xml command line XML tool (formating)
xmllint

# shared library dependencies
# shared library / shared object dependencies
ldd --verbose $(which vim)

# calculate the size of a shared library / shared object with its dependencies
# TODO The calculation doesn't work recursively. A shared object can require
# other shared objects. See https://news.ycombinator.com/item?id=39232976#39250540
guile=$(readlink -f $(which guile))
sizes=$({ echo $guile; ldd $guile|grep /|sed 's+^[^/]*\(/[^ ]*\).*+\1+'; }|xargs -n 1 readlink -f|xargs du -ab|cut -f 1)
sumsize=0
for size in $sizes; do
sumsize=$((sumsize+size));
done
echo $sumsize

# :library find out if libgconf is installed
# -p, --print-cache Print cache
ldconfig --print-cache | grep libgconf
Expand Down
3 changes: 3 additions & 0 deletions notes/editors/emacs.scrbl
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,9 @@
}

@block{@block-name{Various}
;; default value of an an optional parameter is nil
((lambda (a &optional b) (list a b)) 'a) ; => (a nil)

;; check if FILENAME directory exists / is an existing directory
(file-directory-p FILENAME)

Expand Down

0 comments on commit 6725069

Please sign in to comment.