Jump to content

Planned Disruption - Migration to git and Gitea


Itms
 Share

Recommended Posts

8 hours ago, Itms said:

I'm going to add a script for copying the nightly windows prebuilt files into the git repo. That way you would be able to modify in the git repo and test there without back and forth. I already did that for pulling translations and spirv shaders, I could also do that for the built game (it would obviously be Windows-only, but that would cover team artists).

Friendly reminder that us Linux users can run the EXE so it isn't!

 

  • Like 1
Link to comment
Share on other sites

On 02/09/2024 at 8:44 AM, Itms said:

I'm going to add a script for copying the nightly windows prebuilt files into the git repo. That way you would be able to modify in the git repo and test there without back and forth. I already did that for pulling translations and spirv shaders, I could also do that for the built game (it would obviously be Windows-only, but that would cover team artists).

Done! I grouped together all the features in a single script.

In an up-to-date git clone, you can run the script "binaries/system/get-nightly-binaries" to download the built game, the translations, and the Vulkan shaders. All of those files are ignored by git and will not interfere with your workflow as artists.

  • Like 1
Link to comment
Share on other sites

7 hours ago, Itms said:

Done! I grouped together all the features in a single script.

In an up-to-date git clone, you can run the script "binaries/system/get-nightly-binaries" to download the built game, the translations, and the Vulkan shaders. All of those files are ignored by git and will not interfere with your workflow as artists.

This is nice. Is there a way I can rebase my main branch off of 0ad/0ad?

Link to comment
Share on other sites

On 05/09/2024 at 2:21 AM, wowgetoffyourcellphone said:

This is nice. Is there a way I can rebase my main branch off of 0ad/0ad?

Ahoy, sorry for not answering sooner.

You'll have to use the command-line only once so that your clone is aware of the existence of the "upstream" repository 0ad/0ad. (I'm a bit baffled to see this is not supported by Github Desktop (and everyone is pissed off in their bugtracker), but alas.)

Go to your clone, and inside of it, right click and open Git Bash.

Run the command

git remote add 0ad https://gitea.wildfiregames.com/0ad/0ad.git

and exit Git Bash.

Now in Github Desktop, you can rebase in two steps. First, click the "Fetch origin" button at the top. It should display in quick succession "Fetching origin" then "Fetching 0ad", the latter indicates that it becomes aware of changes in the main repository.

Then, in order to rebase your own branch, you use Branch > Rebase current branch, and you select 0ad/0ad as the base branch.

Let me know if something is afoot.

Link to comment
Share on other sites

3 minutes ago, Gurken Khan said:

Eventually, clicking on "Development" will not lead to trac? And the "future" redirections will go? (I don't know exactly how they're supposed to work, but for example trying to use it from /log/ps results in an error message.)

Yeah the links are bit inconsistent right now.

Link to comment
Share on other sites

Thanks for that huge migration work.

On 22/08/2024 at 2:41 PM, Itms said:

In a nutshell:

  • If you are a regular player just regularly testing the latest development version: you should ditch your svn copy and instead clone the new "nightly-build" svn repository at https://svn.wildfiregames.com/nightly-build/trunk. Use "svn update" as usual to get the latest changes daily

 

So it's a git+svn workflow? Does that mean the game files are now spread across two repositories? On part on the git repo and the rest on an svn repo?

  • Like 1
Link to comment
Share on other sites

8 hours ago, tuxayo said:

So it's a git+svn workflow? Does that mean the game files are now spread across two repositories? On part on the git repo and the rest on an svn repo?

It is a git workflow, on a single repository.

SVN is still used as a storage solution for two things, but not for storing the development history, i.e. it is not our VCS anymore.

  1. We still have some bundled libraries for building the game, they are stored in SVN but we'll get rid of that over time. It's a bit arcane and as a contributor you should not be concerned about it.
  2. Additionally, we continuously deliver a nightly built version of the game so that players can test the latest version without any knowledge of git. This uses SVN because our community is used to it by now. SVN allows users to update their nightly build incrementally, without having to re-download everything daily. Release bundles will also be automatically packaged using the nightly build.
  • Like 1
Link to comment
Share on other sites

  • 3 weeks later...
1 hour ago, Gurken Khan said:

I wanted to point someone to the FAQ, but the gitea version looks like an "AI" generated placeholder, no pics, lots of raw html... So if anybody were to look for something useful to do: I think the wiki could use some love...

I'm already on it. Give me a few more days.

  • Like 2
  • Thanks 1
Link to comment
Share on other sites

My config:

 

$ cat .git/config
 

Quote

[core]
    repositoryformatversion = 0
    filemode = true
    bare = false
    logallrefupdates = true
[remote "origin"]
    url = git@gitea.wildfiregames.com:andy5995/0ad.git
    fetch = +refs/heads/*:refs/remotes/origin/*
[branch "main"]
    remote = origin
    merge = refs/heads/main
[lfs]
    repositoryformatversion = 0
[remote "upstream"]
    url = https://gitea.wildfiregames.com/0ad/0ad
    fetch = +refs/heads/*:refs/remotes/upstream/*

 

I first used 'git fetch upstream' and then 'git rebase upstream/main' I get this error:

Quote

 

$ git rebase upstream/main
Downloading binaries/data/mods/public/art/textures/ui/tipdisplay/bullet-point.png (314 B)
Error downloading object: binaries/data/mods/public/art/textures/ui/tipdisplay/bullet-point.png (eea1fcf): Smudge error: Error downloading binaries/data/mods/public/art/textures/ui/tipdisplay/bullet-point.png (eea1fcf91b908608b324d3cbc338f910e6bad9be3a61e8d2c13cacad2c9e5df3): [eea1fcf91b908608b324d3cbc338f910e6bad9be3a61e8d2c13cacad2c9e5df3] Not Found: [404] Not Found

Errors logged to '/home/andy/src/0ad.gitea/.git/lfs/logs/20241009T063439.252465531.log'.
Use `git lfs logs last` to view the log.
error: external filter 'git-lfs filter-process' failed
fatal: binaries/data/mods/public/art/textures/ui/tipdisplay/bullet-point.png: smudge filter lfs failed

 

 

 

 

 

Edited by andy5995
Link to comment
Share on other sites

Quote

 

$ git lfs logs last
git-lfs/3.5.1 (GitHub; linux amd64; go 1.22.1)
git version 2.46.0

$ git-lfs filter-process
Error downloading object: binaries/data/mods/public/art/textures/ui/tipdisplay/bullet-point.png (eea1fcf): Smudge error: Error downloading binaries/data/mods/public/art/textures/ui/tipdisplay/bullet-point.png (eea1fcf91b908608b324d3cbc338f910e6bad9be3a61e8d2c13cacad2c9e5df3): batch response: Repository or object not found: https://gitea.wildfiregames.com/0ad/0ad/objects/batch
Check that it exists and that you have proper access to it

Repository or object not found: https://gitea.wildfiregames.com/0ad/0ad/objects/batch
Check that it exists and that you have proper access to it
github.com/git-lfs/git-lfs/v3/errors.Errorf
    github.com/git-lfs/git-lfs/v3/errors/errors.go:69
github.com/git-lfs/git-lfs/v3/lfshttp.defaultError
    github.com/git-lfs/git-lfs/v3/lfshttp/errors.go:126
github.com/git-lfs/git-lfs/v3/lfshttp.(*Client).handleResponse
    github.com/git-lfs/git-lfs/v3/lfshttp/errors.go:52
github.com/git-lfs/git-lfs/v3/lfshttp.(*Client).DoWithRedirect
    github.com/git-lfs/git-lfs/v3/lfshttp/client.go:341
github.com/git-lfs/git-lfs/v3/lfsapi.(*Client).doWithCreds
    github.com/git-lfs/git-lfs/v3/lfsapi/auth.go:105
github.com/git-lfs/git-lfs/v3/lfsapi.(*Client).doWithAuth
    github.com/git-lfs/git-lfs/v3/lfsapi/auth.go:68
github.com/git-lfs/git-lfs/v3/lfsapi.(*Client).DoWithAuth
    github.com/git-lfs/git-lfs/v3/lfsapi/auth.go:26
github.com/git-lfs/git-lfs/v3/lfsapi.(*Client).DoAPIRequestWithAuth
    github.com/git-lfs/git-lfs/v3/lfsapi/auth.go:57
github.com/git-lfs/git-lfs/v3/tq.(*tqClient).Batch
    github.com/git-lfs/git-lfs/v3/tq/api.go:94
github.com/git-lfs/git-lfs/v3/tq.Batch
    github.com/git-lfs/git-lfs/v3/tq/api.go:45
github.com/git-lfs/git-lfs/v3/tq.(*TransferQueue).enqueueAndCollectRetriesFor
    github.com/git-lfs/git-lfs/v3/tq/transfer_queue.go:581
github.com/git-lfs/git-lfs/v3/tq.(*TransferQueue).collectBatches.func1
    github.com/git-lfs/git-lfs/v3/tq/transfer_queue.go:470
runtime.goexit
    runtime/asm_amd64.s:1695
batch response
github.com/git-lfs/git-lfs/v3/errors.newWrappedError
    github.com/git-lfs/git-lfs/v3/errors/types.go:229
github.com/git-lfs/git-lfs/v3/errors.Wrap
    github.com/git-lfs/git-lfs/v3/errors/errors.go:74
github.com/git-lfs/git-lfs/v3/tq.(*tqClient).Batch
    github.com/git-lfs/git-lfs/v3/tq/api.go:97
github.com/git-lfs/git-lfs/v3/tq.Batch
    github.com/git-lfs/git-lfs/v3/tq/api.go:45
github.com/git-lfs/git-lfs/v3/tq.(*TransferQueue).enqueueAndCollectRetriesFor
    github.com/git-lfs/git-lfs/v3/tq/transfer_queue.go:581
github.com/git-lfs/git-lfs/v3/tq.(*TransferQueue).collectBatches.func1
    github.com/git-lfs/git-lfs/v3/tq/transfer_queue.go:470
runtime.goexit
    runtime/asm_amd64.s:1695
Error downloading binaries/data/mods/public/art/textures/ui/tipdisplay/bullet-point.png (eea1fcf91b908608b324d3cbc338f910e6bad9be3a61e8d2c13cacad2c9e5df3)
github.com/git-lfs/git-lfs/v3/errors.newWrappedError
    github.com/git-lfs/git-lfs/v3/errors/types.go:229
github.com/git-lfs/git-lfs/v3/errors.Wrapf
    github.com/git-lfs/git-lfs/v3/errors/errors.go:85
github.com/git-lfs/git-lfs/v3/lfs.(*GitFilter).downloadFile
    github.com/git-lfs/git-lfs/v3/lfs/gitfilter_smudge.go:134
github.com/git-lfs/git-lfs/v3/lfs.(*GitFilter).Smudge
    github.com/git-lfs/git-lfs/v3/lfs/gitfilter_smudge.go:85
github.com/git-lfs/git-lfs/v3/commands.smudge
    github.com/git-lfs/git-lfs/v3/commands/command_smudge.go:128
github.com/git-lfs/git-lfs/v3/commands.filterCommand
    github.com/git-lfs/git-lfs/v3/commands/command_filter_process.go:131
github.com/spf13/cobra.(*Command).execute
    github.com/spf13/cobra@v1.7.0/command.go:944
github.com/spf13/cobra.(*Command).ExecuteC
    github.com/spf13/cobra@v1.7.0/command.go:1068
github.com/spf13/cobra.(*Command).Execute
    github.com/spf13/cobra@v1.7.0/command.go:992
github.com/git-lfs/git-lfs/v3/commands.Run
    github.com/git-lfs/git-lfs/v3/commands/run.go:154
main.main
    github.com/git-lfs/git-lfs/v3/git-lfs.go:34
runtime.main
    runtime/proc.go:271
runtime.goexit
    runtime/asm_amd64.s:1695
Smudge error
github.com/git-lfs/git-lfs/v3/errors.newWrappedError
    github.com/git-lfs/git-lfs/v3/errors/types.go:229
github.com/git-lfs/git-lfs/v3/errors.NewSmudgeError
    github.com/git-lfs/git-lfs/v3/errors/types.go:315
github.com/git-lfs/git-lfs/v3/lfs.(*GitFilter).Smudge
    github.com/git-lfs/git-lfs/v3/lfs/gitfilter_smudge.go:102
github.com/git-lfs/git-lfs/v3/commands.smudge
    github.com/git-lfs/git-lfs/v3/commands/command_smudge.go:128
github.com/git-lfs/git-lfs/v3/commands.filterCommand
    github.com/git-lfs/git-lfs/v3/commands/command_filter_process.go:131
github.com/spf13/cobra.(*Command).execute
    github.com/spf13/cobra@v1.7.0/command.go:944
github.com/spf13/cobra.(*Command).ExecuteC
    github.com/spf13/cobra@v1.7.0/command.go:1068
github.com/spf13/cobra.(*Command).Execute
    github.com/spf13/cobra@v1.7.0/command.go:992
github.com/git-lfs/git-lfs/v3/commands.Run
    github.com/git-lfs/git-lfs/v3/commands/run.go:154
main.main
    github.com/git-lfs/git-lfs/v3/git-lfs.go:34
runtime.main
    runtime/proc.go:271
runtime.goexit
    runtime/asm_amd64.s:1695

Current time in UTC:
2024-10-09 11:47:48

Environment:
LocalWorkingDir=/home/andy/src/0ad.gitea
LocalGitDir=/home/andy/src/0ad.gitea/.git
LocalGitStorageDir=/home/andy/src/0ad.gitea/.git
LocalMediaDir=/home/andy/src/0ad.gitea/.git/lfs/objects
LocalReferenceDirs=
TempDir=/home/andy/src/0ad.gitea/.git/lfs/tmp
ConcurrentTransfers=8
TusTransfers=false
BasicTransfersOnly=false
SkipDownloadErrors=false
FetchRecentAlways=false
FetchRecentRefsDays=7
FetchRecentCommitsDays=0
FetchRecentRefsIncludeRemotes=true
PruneOffsetDays=3
PruneVerifyRemoteAlways=false
PruneVerifyUnreachableAlways=false
PruneRemoteName=origin
LfsStorageDir=/home/andy/src/0ad.gitea/.git/lfs
AccessDownload=none
AccessUpload=none
DownloadTransfers=basic,lfs-standalone-file,ssh
UploadTransfers=basic,lfs-standalone-file,ssh
GIT_SEQUENCE_EDITOR=:
GIT_EXEC_PATH=/usr/lib/git-core
GIT_PREFIX=

 

 

Link to comment
Share on other sites

21 hours ago, andy5995 said:

@trompetin17 gave me the solution on IRC and I'll update the docs within the next day or two.

I documented the fix https://gitea.wildfiregames.com/0ad/0ad/wiki/BuildInstructionsGettingTheCode

The current heading is "Recovering from errors while syncing your fork". I won't link to it directly because the section hasn't been reviewed yet and the heading might change.  @Stan`@trompetin17

  • Like 1
  • Thanks 1
Link to comment
Share on other sites

On 10/10/2024 at 1:37 PM, andy5995 said:

I feel like some command invocations are redundant, but as long as it covers all ways of getting users out of trouble, I don't really mind.

On 09/10/2024 at 6:32 PM, real_tabasco_sauce said:

@Itms, I'm not sure if this is something you can change, but the top left button (WFG logo), seems to link to my personal dashboard.

I think it would be nice if this linked to either https://gitea.wildfiregames.com/0ad/0ad or https://gitea.wildfiregames.com/0ad

The top-left button brings you to the root of the subdomain, https://gitea.wildfiregames.com. I think any other destination would be very unexpected for a top-left button, it would certainly confuse me.

However, I could definitely add a "Main repository" button in that top bar. I can even make it a 0ad-wheel-logo instead of a text button. I would place it in second position, just right of the WFG logo button. Would that sound good to you guys?

  • Thanks 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...