share a local mercural project - mercurial

I started some local mercurial projects which I would like to start sharing.
I use ubuntu and netbeans, and I have a ssh machine which would host the projectes.
How could I "upload" them to the server so other users could download?

Have a look at the A tour of Mercurial: the basics section "Sharing changes over a network". One of the hosting options is Bitbucket.

Related

How Does Mercurial Communicate Changes Between Clients?

Forgive me if this question sounds ridiculously naive, but I don't seem to be able to find a straightforward answer to this anywhere.
I am considering using Mercurial for source control on a small (2-3 developers) project. I like the idea of not having to subscribe to a central repository, and I like that everyone effectively has a complete copy of the project. What I don't understand is how the Mercurial clients communicate changes to each other. Does it require opening a specific port or something similar?
Any pointers to help on Mercurial or comments from people who have used it would be gratefully received.
Mercurial can access remote repositories in a number of ways. The main ones are:
File access (i.e. look at the repo at this path)
HTTP / HTTPS (i.e. look at the repo being served at this web address)
SSH (i.e. log into this machine / user, and look at the repo at this path)
The first only really works if your team is all working on a shared file-system, but is also useful if you personally have multiple clones that you want to move information between.
HTTP is how you would access something like Bitbucket, or some other "available to all" server. You can set-up a temporary server on a machine with the command hg serve, and that's useful if you need to share with a colleague quickly and don't care about security, but normally HTTP Mercurial servers sit behind Apache, or some other web server software.
An SSH based set-up is just a machine running an SSH server which has Mercurial installed. Mercurial logs on to the machine, and invokes hg remotely. The local hg and the remote hg then talk over the link. Very easy to set-up in my opinion. Credentials are all handled in normal SSH ways.
Further reading:Publishing Repositories

Mercurial Introduction - BitBucket and 3rd Party Server Issue

I have just started working on a web project that uses Mercurial version control system to a bitbucket account.
The web project is hosted on a 3rd party server - Webfaction.
I have followed all the Mercurial tutorials at Mercurial
The tutorials state that a repository should be made on the local pc and then changes made to the code in the repository on the local pc and then added, committed and pushed to the bitbucket account.
But my project is hosted on a server - WebFaction, so all the code changes should happen on the server, so I can see that the changes work.
I cannot find a reference to changing the code on the WebFaction server (only on the local pc) and then committing and pushing the code from the WebFaction server to the bitbucket account. I simply don't know how to do this (or even if it can be done!).
Can someone give me the steps and syntax (as much as possible) to do this? Could you also keep the answers as simple as possible as there are huge parts of Mercurial I don't yet understand.
Thanks.
Assuming you have full SSH access to the WebFaction server (you should according to the WebFaction features page), I suggest you try following the detailled instructions found here. If you get stuck on any step, then you can ask a more specific question (probably better to ask on serverfault though).
The fact that the repository is on a remote server does not really change anything. You connect through SSH to the remote server (WebFaction) and you follow the steps as if it was a local machine.

Is system-wide Mercurial installation enough in a shared enviroment?

I am learning how I can install Mercurial on our team system, but I am not experienced enough to make some decision.
For our team, we have a server machine used as a repository. Every team member also has her/his own Linux RedHat installed machine. However, we do not do anything on our local terminals and we do everything on the server. Every member has a user directory on the server such as /home/Cassie, /home/john, ... and we save all our code and work there. When we turn on the local terminals, the GNOME system shows our personal files on the server not the local machine. Whenever everyone click the terminal application on desktop, it connects to her own home directory. Thus, we do not need to use SSH command to connect to the server. It is like the school multi-users system. Everyone has a user account and she logs into her own account to do her own work. I hope I can install a shared repository on that server and every one can do push, pull, etc. all kind of commands there.
1) Since we use a shared environment, does it mean that I need to install Mercurial on only the server and that is enough for everyone to do "commit", "push", "pull", etc. commands?
2) By installing only system-wide Mercurial, does it eliminate the ability to do local commit? If I would like to let everyone still have the "local commit" ability, how should I do it?
3) I have searched online. Some people mentioned that for a shared network server, it is impossible to have locks for any two users if they are trying to access the same file at the same time. Does it imply my situation?
In sum, we do all the work on the server. I hope to find a plan to have Mercurial control on a repository shared by everyone when everyone still has local commit ability and the repository still has some locks protection if any two users try to access a file at the same time. If this scenario is feasible, can I just install the Mercurial on the server or I need to install Mercurial for both servers and users machines? If it is impossible for the scenario, would someone please suggest me a plan to have version control for our system?
1) Since we use a shared environment, does it mean that I just need to install the Mercurial on the server and it is enough for everyone to do "commit","push","pull"..etc commands ?
If your users are logging into a shell on the server in order to do their work, then yes it is sufficient to have Mercurial installed only on the server.
2) By installing only system-wide Mercurial, does it eliminate the ability to do local commit ? If I would like to let everyone still have the "local commit" ability, how should I do it ?
Your users will presumably checkout from a shared "root" repository into their own home directory in order to work on the code. They will have a "local" copy of the repo in their home directory and will push into the shared root repository.
3) I have searched online. Some people mentioned that for a shared network server, it is impossible to have locks for any two users if they are trying to access the same file at the same time. Does it imply my situation ?
As long as your users are working within their own local copies of the repo, they will not interfere with one another. The only time a conflict may arise is when committing back to the shared root repository -- in which case the user will need to merge their changes and resolve any conflicts.
I would recommend reading carefully through Joel Spolsky's excellent Hg Init tutorial for a better understanding of how Mercurial handles "central" and "local" copies.

Need: Version control - install with only ftp/mysql access

I would like to host my own version control on the server I already pay for. I don't have shell access, but I can use ftp (obviously) and mysql. Are there any version control solutions that can run with only these?
I don't think Subversion or CVS will work without software installation. Can you mount your account as a file share/network drive? If so Mercurial would work. You could keep your master repo in the folder and clone it onto your local hard drive for real work. If you're just looking for a remote repository solution, you might be able to use Mercurial or Git with DropBox in the same way.
This is just my opinion, but if any provider ever told me they don't support SSH because of security I would immediately cancel my account and get a new provider. Let me guess: they only do Windows server hosting?
If you need to keep your project private you could always use a paid GitHub or BitBucket account as well, but that doesn't solve the problem of hosting on your existing account.
Straight out of git's man page:
Git natively supports ssh, git, http, https, ftp, ftps, and rsync protocols.
Rsync works over FTP, so you could have a local folder that represents what you want on the host, and then use rsync to deploy it.

Host Mercurial on my company's intranet?

Instead of using an external web-based Mercurial host, I want to set one up on my company's intranet. Is there a web-based tool for Mercurial that lets you have an interface like Bitbucket's but let's you host Mercurial locally?
Mercurial ships with hgwebdir.cgi, which can be configured to provide a basic interface for repository hosting. It's quite straightforward to setup with Apache.
I use this on my OSX box at home; took about an hour - most of that was permissions related to kludging in server operations on a desktop box.
It's not Bitbucket. If you have a decent-sized budget, you might be able to purchase a bitbucket license for your company - I don't know.
Hgwebdir provides you a web interface for your hg repos. It's little simpler than what your can get from Bitbucket but good enough.
You have to setup a webserver(apache) and mercurial on a server.
With Deveo you can manage Mercurial, Git and Subversion repositories, as well as WebDAV repositories for binary storage. It also has other features such as project Wiki's and issue tracking, which makes it like Github/Gitlab but with support for multiple VCS's.
(Disclaimer: I'm working at Deveo)
codeBeamer is a complete Application Lifecycle Management platform that does everything that BitBucket and more. It comes with commercial support, and can be installed on any Java compliant server, also behind your company firewall.
The space is limited here to go into details, but the codeBeamer user guide should answer all your questions.
(Disclaimer: we are the developers of the product.)