Skip to content

Add Windows support #21

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
christian-monch opened this issue Oct 23, 2024 · 0 comments · Fixed by #83
Closed

Add Windows support #21

christian-monch opened this issue Oct 23, 2024 · 0 comments · Fixed by #83

Comments

@christian-monch
Copy link
Contributor

christian-monch commented Oct 23, 2024

Windows is currently not supported because:

  1. It seems that git-annex does not work with git-worktree on Windows.
  2. Tests rely on commands not generally available on Windows, e.g. echo.

Recreate the Windows error

The following commands in a PowerShell console in Windows demonstrate the git-annex issue, i.e. it is not possible to the content of the annexed file a.txt in the worktree.

> datalad create test-ds
> cd test-ds
> write-output some_content > a.txt
> datalad save
> git worktree add wt-1
> cd wt-1
> cat .\a.txt
/annex/objects/MD5E-s30--5e21038aabfc0c59d172ea1d7a64cc67.txt
> datalad get a.txt
get(error): a.txt (file) [not available]
[{'action': 'get',
  'annexkey': 'MD5E-s30--5e21038aabfc0c59d172ea1d7a64cc67.txt',
  'message': 'not available',
  'path': 'C:\\Users\\test-user\\tmp\\test-ds\\wt-1\\a.txt',
  'refds': 'C:\\Users\\test-user\\tmp\\test-ds\\wt-1',
  'status': 'error',
  'type': 'file'}])
mih added a commit to datalad/datalad-core that referenced this issue Oct 25, 2024
mih added a commit to datalad/datalad-core that referenced this issue Oct 25, 2024
mih added a commit to datalad/datalad-core that referenced this issue Oct 25, 2024
mih added a commit to datalad/datalad-core that referenced this issue Oct 25, 2024
mih added a commit to datalad/datalad-core that referenced this issue Oct 25, 2024
mih added a commit to datalad/datalad-core that referenced this issue Oct 25, 2024
mih added a commit to datalad/datalad-core that referenced this issue Oct 25, 2024
mih added a commit to datalad/datalad-core that referenced this issue Oct 25, 2024
christian-monch added a commit that referenced this issue Jan 22, 2025
This PR fixes issue #21 <#21>

It uses `git clone` instead of `git worktree` to create a worktree in a
Windows environment.
Tests use PowerShell commands in a Windows environment.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant