[HOME] [DOWNLOAD] [DOCS] [NEWS] [SUPPORT] [TIPS] [ISSUES] [DONATE]

[solved] git checkout problem

Hello,

i’m trying to build Whonix 9 from Source. Unfortunately it fails in early stage, because the simple ‘git checkout 9’ does not work.

Build system is a Debian Wheezy VM explicit to build Whonix. In the past Whonix 8.2 where build without problems.

I have followed the Documentation at http://xxxxxxxxxxh5kyrx.onion/wiki/Dev/Build_Documentation/9_full

The concerning part:

user@localhost:~/Whonix$ git tag
.1.3
0.2.1
0.3.0
0.3.1
0.4.0
0.4.1
0.4.2
0.4.3
0.4.4
0.4.5
0.4.5-fix1
0.4.5-fix2
0.4.5.1
0.5.1
0.5.2
0.5.3
0.5.4
0.5.5
0.5.6
0.6.0
0.6.1
6
6.1
6.2
7
7.1
7.2
7.3
7.3.1
7.3.2
7.3.3
7.3.4
7.3.5
7.3.6
7.3.7
7.7.6.4
7.7.8.6
7.7.8.7
7.7.8.8
7.7.8.9
7.7.9.1
7.7.9.3
7.7.9.7
7.7.9.8
8
8.1
8.2
8.5.0.2
8.6.2.8
8.6.6.0
9

user@localhost:~/Whonix$ git tag -v 9
object b03ffe3e93b41b6922d1d04bebffc4483dc873d5
type commit
tag 9
tagger Patrick Schleizer <adrelanos@riseup.net> 1410988892 +0000

.
gpg: Signature made Wed 17 Sep 2014 05:21:33 PM EDT using RSA key ID 77BB3C48
gpg: Good signature from "Patrick Schleizer <adrelanos@riseup.net>"
gpg: WARNING: This key is not certified with a trusted signature!
gpg:          There is no indication that the signature belongs to the owner.
Primary key fingerprint: 916B 8D99 C38E AF5E 8ADC  7A2A 8D66 066A 2EEA CCDA
     Subkey fingerprint: 6E97 9B28 A6F3 7C43 BE30  AFA1 CB8D 50BB 77BB 3C48

user@localhost:~/Whonix$ git checkout 9
HEAD is now at b03ffe3... .

user@localhost:~/Whonix$ git status
# Not currently on any branch.
# Untracked files:
#   (use "git add <file>..." to include in what will be committed)
#
#       packages/apparmor-profile-gwenview/
#       packages/kde-privacy/
nothing added to commit but untracked files present (use "git add" to track)

Didn’t run ‘git status’ on first try. Fails at 1200_create-debian-packages ‘git status --porcelain’

user@localhost:~/Whonix$ git status --porcelain
?? packages/apparmor-profile-gwenview/
?? packages/kde-privacy/

Would be glad for help.

–nonsense–

No mistake on your side.

Seems like a limitation on how git manages git submodules. These folders have been added after the release of Whonix 9. Git does not hide them when doing the checkout.

The quick fix is to get rid of these folders.

Show them.

If that looks sane, wipe them.

Let’s see if there is a better solution.

[quote=“Patrick, post:3, topic:520”]If that looks sane, wipe them.

Let’s see if there is a better solution.[/quote]

According to ‘man git-clean’ i had to use ‘-f’ twice.

-d Remove untracked directories in addition to untracked files. If an untracked directory is managed by a different git repository, it is not removed by default. Use -f option twice if you really want to remove such a directory.

Yes, solves the problem of the new added packages. But in the meantime i had to clone the git again and have a lot of packages with new commits who don’t get reverted trough ‘git clean’.

user@localhost:~/Whonix$ git status
# Not currently on any branch.
# Changes not staged for commit:
#   (use "git add <file>..." to update what will be committed)
#   (use "git checkout -- <file>..." to discard changes in working directory)
#
#       modified:   packages/anon-meta-packages (new commits)
#       modified:   packages/anon-shared-build-apt-sources-tpo (new commits)
#       modified:   packages/anon-shared-helper-scripts (new commits)
#       modified:   packages/apparmor-profile-anondist (new commits)
#       modified:   packages/control-port-filter (new commits)
#       modified:   packages/msgcollector (new commits)
#       modified:   packages/rads (new commits)
#       modified:   packages/sdwdate (new commits)
#       modified:   packages/tb-default-browser (new commits)
#       modified:   packages/tb-updater (new commits)
#       modified:   packages/timesync (new commits)
#       modified:   packages/whonixcheck (new commits)
#       modified:   packages/whonixsetup (new commits)
#
no changes added to commit (use "git add" and/or "git commit -a")

Could only find the option trough discard them by ‘git reset --hard’

user@localhost:~/Whonix$ git reset --hard
HEAD is now at b03ffe3 .

but unfortunately this doesn’t works as expected:

user@localhost:~/Whonix$ git status
# Not currently on any branch.
# Changes not staged for commit:
#   (use "git add <file>..." to update what will be committed)
#   (use "git checkout -- <file>..." to discard changes in working directory)
#
#       modified:   packages/anon-meta-packages (new commits)
#       modified:   packages/anon-shared-build-apt-sources-tpo (new commits)
#       modified:   packages/anon-shared-helper-scripts (new commits)
#       modified:   packages/apparmor-profile-anondist (new commits)
#       modified:   packages/control-port-filter (new commits)
#       modified:   packages/msgcollector (new commits)
#       modified:   packages/rads (new commits)
#       modified:   packages/sdwdate (new commits)
#       modified:   packages/tb-default-browser (new commits)
#       modified:   packages/tb-updater (new commits)
#       modified:   packages/timesync (new commits)
#       modified:   packages/whonixcheck (new commits)
#       modified:   packages/whonixsetup (new commits)
#
no changes added to commit (use "git add" and/or "git commit -a")

The first, works for me.

git clean -ndf Would remove packages/apparmor-profile-gwenview/ Would remove packages/kde-privacy/

git clean -df Removing packages/apparmor-profile-gwenview/ Removing packages/kde-privacy/

But in the meantime i had to clone the git again and have a lot of packages with new commits who don't get reverted trough 'git clean'.

Those are different. After checking out the tag, such as “git checkout 9” git just does has not checked out the git modules as recorded by the tag. This can be done using.

However, this is automated in the build-steps.d/1100_prepare-build-machine build step.

By the way, after running build-steps.d/1200_create-debian-packages there will be temporary files. Those can be cleaned up by help-steps/cleanup-files and are documented here. (https://www.whonix.org/wiki/Dev/Build_Documentation/9_full#Cleanup)

[quote=“Patrick, post:6, topic:520”]The first, works for me.

git clean -ndf Would remove packages/apparmor-profile-gwenview/ Would remove packages/kde-privacy/

git clean -df Removing packages/apparmor-profile-gwenview/ Removing packages/kde-privacy/[/quote]

But there are still present on my system trough this command. A ‘git checkout 9’ and / or ‘git status’ don’t display them. A ‘git status --porcelain’ do it, so it would still fail at 1200_create-debian-packages.

[quote=“Patrick, post:6, topic:520”][…]
Those are different. After checking out the tag, such as “git checkout 9” git just does has not checked out the git modules as recorded by the tag. This can be done using.

However, this is automated in the build-steps.d/1100_prepare-build-machine build step.
[…][/quote]

Thanks for the hint. I didn’t start a build, because i was confused about the new commits.
Just now the build process runs without a notable error message.

Will write a short update after successful building. But i guess it’s solved.

You were right. This really requires.

Updated build documentation.

Thanks for your help. The VM’s were build successful. But ran into another problem with the created builds. Will open a new thread after some tests.

[Imprint] [Privacy Policy] [Cookie Policy] [Terms of Use] [E-Sign Consent] [DMCA] [Investors] [Priority Support] [Professional Support]