# windows_drive.sh - two things to know before you build your own image.
# It makes a sandbox of its own, named plain, and removes it at the end.
# The second half only means something inside WSL on Windows.

# 1. The image a sandbox gets when you name none has neither curl nor Python.
openshell sandbox create --name plain --detach
openshell sandbox exec -n plain -- curl --version
openshell sandbox exec -n plain -- python3 --version

# 2. Upload one file twice: from the Windows drive, and from this Linux folder.
cp ask_github.py /mnt/c/Users/Public/from_windows_drive.py
openshell sandbox upload plain /mnt/c/Users/Public/from_windows_drive.py
openshell sandbox upload plain ask_github.py

# The same length. Compare the fingerprints, and look at the first bytes.
sha256sum ask_github.py
openshell sandbox exec -n plain -- sh -c 'wc -c *.py; sha256sum *.py'
openshell sandbox exec -n plain -- sh -c 'od -c from_windows_drive.py | head -2'

rm /mnt/c/Users/Public/from_windows_drive.py
openshell sandbox delete plain
