Code on Github/Gitlab/Bitbucket

Game development with Board Game Arena Studio
User avatar
RockAndSka
Posts: 5
Joined: 19 August 2015, 20:36

Re: Code on Github/Gitlab/Bitbucket

Post by RockAndSka » 08 November 2019, 19:59

Since i was looking to this too, i was wondering why all games are not on github or another git sharing.

It will be really convenient because it will allow :

- to do pull request reviewed by main developers to fix some bug faster than today since original author are not available to fix the games
- to add visibility to the code base of all games on BGA
- to be able to develop / participate in game development without having to create a dedicated account for this ( why an account is needed to see licenses, bounty, and another ressource)
- leverage CI and automatic deploy new version
- etc...

Regards,

Maco_
Posts: 1
Joined: 14 May 2020, 22:52

Re: Code on Github/Gitlab/Bitbucket

Post by Maco_ » 14 May 2020, 23:22

Hi, I'm a developer and I'll love to contribute in the development in some games: bug fixing or creating new ones. But only thinking about using sftp stops me to do that. Using git it's kind of a standard right now in the industry. And if we are talking about Open Source Github is the place where nearly all the development is done.

Github is know for all it's tools to make it easy to contribute to a project. We know that get new contributors for a game is difficult and if we hide how to start the development behind no standard ways it's even more difficult.

I usually play with other 3 friends/developers and we always talk about that we would love to contribute. The thing is that we all read the presentation and thought: This is not open source. So we just complain and dream for an Open Source BGA (not all the page, just the code of the games). I just find this thread and I think that we are mistaken. That it is open source but it doesn't follow any "open source convention".

I think that I'm talking too much withoud a clear point. So here's my point: If you want more developers to contribute I recommend to move the framework to more standard tools. Use github, create a repository for each game. Remove entry barriers. Any developer can download the code without a register. Once they play with the code, and they find a fix or develop a new game they will find the way to contribute. But at that moment they will have something to contribute so the barriers to do it doesn't seem so tall.

User avatar
Loreroth
Posts: 12
Joined: 05 August 2014, 07:28

Re: Code on Github/Gitlab/Bitbucket

Post by Loreroth » 15 May 2020, 01:52

Its a bit of a old post but using external version control systems like github by developers is fully allowed and encouraged. You are fully allowed to develop your projects with git. ftp is only needed to upload the code to bga's servers for testing and release. There are apps such as winscp that will watch for changes and automatically upload them.

It's not perfect but its workable.

RailRunner
Posts: 10
Joined: 27 April 2020, 15:04

Re: Code on Github/Gitlab/Bitbucket

Post by RailRunner » 15 May 2020, 21:37

The problem is also that the developers and administrators have a finite amount of resources. They have to choose what to develop and developing a new system based on git / ci and what not takes a lot of time.

That's not to say I would say no if they would go that route. All the projects I work on have at least git + a CI, so the games on BGA do the same, only they're synced to SFTP as well.

User avatar
LaszloK
Posts: 23
Joined: 05 January 2018, 19:00

Re: Code on Github/Gitlab/Bitbucket

Post by LaszloK » 17 May 2020, 10:43

To add my 2p - I personally mess around in the code a lot before I commit anything, and then also rebase it a lot (I use git locally) so I'm not too keen on using something that synchronizes automatically. I'm using WinSCP which has that feature, but as of now I prefer hitting Synchronize manually every so often.

Now would it be more convenient to be able to use the same command line and git push to BGA Studio? Sure. Would it be WAY more convenient to be able to do that and work in branches if I was collaborating with others (which I'm currently not)? You bet. But "a terribly inconvenient protocol to work with even on single-developer projects"? That's taking it way too far in my opinion.

[Edit] Oh and before I forget: The BGA licence is such that there is a limit on who can see my code, who can reuse it, and for what purpose. It's not too complicated to get hold of it, but it won't just show up on Google like most FOSS projects will, and I actually prefer it to be that way - if for no other reason then because I've seen (and signed) employment contracts containing an explicit prohibition on contributing to FOSS projects unless specifically discussed and agreed to in writing first by management. Although I'm not under one of those contracts right now, it would still seriously complicate matters for me if the entire studio were to suddenly move to github or anything similar.

User avatar
Spukyta
Posts: 5
Joined: 11 May 2020, 16:01

Re: Code on Github/Gitlab/Bitbucket

Post by Spukyta » 25 May 2020, 14:02

Hi all,
I have a repo in GitHub and I use a GitHub Action so the code is pushed via SFTP to BGA studio server each time I push to master.
The credit of the action goes to its creator: https://github.com/SamKirkland/FTP-Deploy-Action
Steps:
1 - Create a secret in the repo to store the FTP password (Repo -> Settings -> Secrets -> New secret) and name it (in example below YOUR_BGA_FTP_PASSWORD), so you can use it in an Action.
2 - Create a new Action with the code below changing the data in caps (Repo -> Actions -> New workflow -> set up a workflow yourself).
3 - Commit and enjoy! :mrgreen:

Code: Select all

on: push
name: Publish Website over SFTP
jobs:
  FTP-Deploy-Action:
    name: FTP-Deploy-Action
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2.1.0
      with:
        fetch-depth: 2

    - name: FTP-Deploy-Action
      uses: SamKirkland/FTP-Deploy-Action@3.1.1
      with:
        ftp-server: sftp://1.studio.boardgamearena.com/YOUR_GAME_FOLDER/
        ftp-username: YOUR_BGA_USER_NAME
        ftp-password: ${{ secrets.YOUR_BGA_FTP_PASSWORD }}
        git-ftp-args: --insecure # if your certificate is setup correctly this can be removed (see known-hosts argument)
When I'm fixing small things I enable SFTP sync in Visual Studio Code with an extension (https://marketplace.visualstudio.com/it ... imomo.sftp ) and the following conf. To disable it change "uploadOnSave" to false.

Code: Select all

{
    "name": "BGA",
    "host": "1.studio.boardgamearena.com",
    "protocol": "sftp",
    "port": 22,
    "username": "YOUR_USERNAME",
    "password": "YOUR_SFTP_PWD",
    "remotePath": "/YOUR_FOLDER_NAME",   
    "uploadOnSave": true
} 
Last edited by Spukyta on 15 July 2020, 16:34, edited 1 time in total.

User avatar
Draasill
Posts: 108
Joined: 26 April 2020, 00:00

Re: Code on Github/Gitlab/Bitbucket

Post by Draasill » 25 May 2020, 15:20

Note about github, it would be great that projects all have a tag "boardgamearena" in order for them to appear on the search : https://github.com/topics/boardgamearena

User avatar
mujina93
Posts: 3
Joined: 11 July 2020, 14:06

Re: Code on Github/Gitlab/Bitbucket

Post by mujina93 » 11 July 2020, 15:32

@Spukyta are you able to sync with the VSCode extension? I get a permission denied when I try to sync local -> remote

User avatar
quietmint
Posts: 147
Joined: 31 July 2017, 00:28

Re: Code on Github/Gitlab/Bitbucket

Post by quietmint » 12 July 2020, 06:03

Regarding SFTP, I just found lftp and it works very well. It automatically skips files based on date/size (so it only uploads changes) and it supports parallel transfers, so it's much faster than fuse mount + rsync, which I was using before. I put some setup instructions at http://en.doc.boardgamearena.com/Tools_ ... using_lftp

User avatar
grivin
Posts: 6
Joined: 23 September 2012, 10:39

Re: Code on Github/Gitlab/Bitbucket

Post by grivin » 13 July 2020, 11:35

Draasill wrote:
25 May 2020, 15:20
Note about github, it would be great that projects all have a tag "boardgamearena" in order for them to appear on the search : https://github.com/topics/boardgamearena
nice idea.
Updated mine with #boardgamearena (was using #board-game-arena and #bga)

Post Reply

Return to “Developers”