== FreeBSD and POSIX compliance issues == http://lists.freebsd.org/pipermail/freebsd-standards/2010-April/001936.html == Deleting partitions == sh -c 'set -x; for i in `cd /dev/; ls *p*`; do echo gpart delete -i ${i##*p} ${i%p*}; done' sh -c 'set -x; for i in `cd /dev/; ls ad*p*`; do echo gpart delete -i ${i##*p} ${i%p*}; done' sh -c 'set -x; for i in `cd /dev/; ls da[0-9]* | grep -v s`; do gpart destroy -F $i; done' == Loading the usr-tests.md.xz mfsroot at boot == load -t mfs_root /usr-tests.md.xz == Getting FreeBSD ports to compile on FreeBSD 7 for pain and profit (directions worked with CURRENT @ ~r267851) == 1. echo `'.include ' > /usr/share/mk/src.opts.mk`. 2. Export the following variables: # Not sure how to get things to work with gcc; ran into -Wshadow problems # with libarchive and times(3), and gcc on the OS didn't support all of the # keywords that clang did (restrict for instance). export CC=clang FORCE_PKG_REGISTER=1 MK_ICONV=no MK_GCC=yes MK_GNUCXX=yes MK_SHARED_TOOLCHAIN=yes MK_TESTS=no MAKESYSPATH=/usr/share/mk NO_WARNING_PKG_INSTALL_EOL=1 3. Install the latest version of gcc/binutils. 4. Turn off spawn.h/posix_spawn support in lib/libarchive/freebsd_config.h. 5. Revert FreeBSD @ r252231 so sed will compile again. 6. Install `usr.bin/bmake lib/lzma lib/libarchive lib/libedit usr.bin/sed usr.bin/tar` 7. Remove RUN_DEPENDS for info in bsd.port.mk. 8. Install `devel/autoconf devel/automake devel/m4` == Figuring out how many commits a FreeBSD developer has using git between two timeframes == Requirements: - Commit notes for SVN revision numbers. - The `upstream` remote be set [to github.com/freebsd/freebsd.git or an equivalent]. author=ngie branches='master stable/10 stable/9' start_date='2015-09-01' end_date='2016-01-01' # This is inclusive git fetch upstream; for branch in master $branches; do # Commit notes num_commits=$(git log --author $author --pretty=format:"%ai %N" --after="$start_date" --before="$end_date" upstream/$branch | sed -e '/^[:space:]*$/d' | wc -l); printf "%24s: %4d\n" "$branch" "$num_commits"; done