# porting reposilite - is svn still the way to go?



## daudo (Jun 23, 2021)

Hi,

I'm in the process of porting reposilite, a lightweight maven repository server and maven proxy. While I have worked with ports some time ago, I am not sure if svn is still the way to go. Somehow I'm sure to have read that it has been superseded by  git, but unfortunately I fail to find information on this. And even worse, I am also somehow sure that the Porters Handbook is not up to date in that regards.

... but who knows, maybe I am just getting old and I am imagining things 

Can someone please enlighten me, if it is svn or git, and, if happens to be git, if the procedures to submit a new port have changed with regards to the Porters Handbook.

Thanks.


----------



## Alexander88207 (Jun 23, 2021)

Hello,

git will now be the way to go.

It is also still possible to send in svn diffs but you will be asked nicely to go with git.

The procedures to submit a new port have not changed, only the commands that do you need to use to create a diff.

I do using the following commands:

To create a diff of only changes: `git diff  > /usr/home/$USER/updatedport.diff`

To add new files to your local repo: `git add /usr/ports/desktop/newport/*`

To create a diff of your new added files: `git diff --staged > /usr/home/$USER/newport.diff`

To create a diff of both in one: `git diff --staged > /usr/home/$USER/newport.diff && git diff >> /usr/home/$USER/newport.diff`


----------



## diizzy (Jun 23, 2021)

Uhm....
Why not just do `git diff --cached > /path/to/my/patchfile-with-all-changes.patch` if you've used git add as it will include all changes?


----------



## SirDice (Jun 24, 2021)

daudo said:


> And even worse, I am also somehow sure that the Porters Handbook is not up to date in that regards.





daudo said:


> if the procedures to submit a new port have changed with regards to the Porters Handbook.


Porter's handbook has been updated accordingly. Make sure you're not looking at an old copy.









						Chapter 11. Upgrading a Port
					

Upgrading a FreeBSD Port




					docs.freebsd.org


----------



## diizzy (Jun 24, 2021)

All "single-page" variants are outdated at this point (known issue)


----------



## astyle (Jun 24, 2021)

I know enough to know that git is the way to go these days.

I am a little surprised that OP was not finding info to point to that - just regular visits to freebsd.org and looking for package info on the official site should have tipped OP off... I think FreeBSD completed a migration to git just earlier this year.

Before 2007, svn was the hot versioning system that every programmer was supposed to know. But now it's git... there's github, gitlab, and nearly every well-known Open Source project out there uses git.


----------



## daudo (Jun 28, 2021)

diizzy said:


> All "single-page" variants are outdated at this point (known issue)


Yes, indeed, I was reading the full version:









						FreeBSD Porter's Handbook
					

Essential reading if you plan on providing a port of a third party piece of software




					docs.freebsd.org
				



I don't like the split version, because it makes it way more difficult to search for things


----------



## astyle (Jun 28, 2021)

daudo said:


> I don't like the split version, because it makes it way more difficult to search for things


Google is your friend. There's also the search function at top of most pages.


----------



## daudo (Jun 28, 2021)

astyle said:


> Google is your friend. There's also the search function at top of most pages.


there is no search function at the top of the split porter's book sections (and any other split freebsd book). And yes, obviously google is your friend, as well as my cat, thanks for letting me know.


----------



## astyle (Jun 28, 2021)

daudo said:


> there is no search function at the top of the split porter's book sections (and any other split freebsd book). And yes, obviously google is your friend, as well as my cat, thanks for letting me know.


Umm... have you tried Ctrl-F? That helps when you have split sections that are too long to scroll. I use that in the User Handbook all the time, Porter's handbook should be similar.


----------



## diizzy (Jun 28, 2021)

daudo said:


> Yes, indeed, I was reading the full version:
> 
> 
> 
> ...


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=256526


----------

