/lib/partman/choose_method/40swap/do_option is in ubiquity 18.04.14.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | #!/bin/sh
dev=$2
id=$3
mkdir -p $dev/$id
if [ -f $dev/$id/method ]; then
old_method=$(cat $dev/$id/method)
else
old_method=do_not_use
fi
echo swap >$dev/$id/method
>$dev/$id/format
rm -f $dev/$id/use_filesystem
|