Add an empty P4 Tool in Assembla
First, you should make sure that you've added a P4 tool to your Assembla Space. Hover over the green (+) button at the top of your screen and select Add P4 Repo to add an empty repository. Then, open the P4 tool and select the Instructions sub-tab. This page will show you important information that you will need to configure your depot with Assembla.
Download and install the latest P4V client from this link.
Select the family and platform. The version is disabled because the latest version is selected by default.
Open the installer and click on Next.
Enter the Assembla p4 server found on your repository's instructions tab and your Assembla username
Click on Start
Click on Finish
Now let’s get the P4 repo in our computer
1. Create a folder in your computer and name it as you want. I will call mine “Assembla_Demo”, take note of the path, you will need it later. Mine is D:\p4\assembla_demo
You can also connect using the old, less comfortable flow with the "p4host" settings file (not recommended). Read more here <ADD LINK>.
2. Open P4V. In you're using Windows, press the Windows key from your keyboard and type "p4v".
3. Enter the server and your username from before. Copy them from your instructions page, perforce is case sensitive and if you type anything wrong, it will throw an error.
Note: Leave the workspace field blank.
4. It will ask you for the encoding, select UTF-8
5. Now enter your Assembla password
6. Congrats, your P4V is now up!
7. If your repository has some content, you will see some workspaces to start working on. In the above example, this is an empty repository and we need to create our first workspace to start. Under Depot, click on “New Workspace…”
8. By default, you will see the workspace name and root with some values. I like to create my workspaces in the same folder where I save my p4config.txt file, so I can easily track where they are and to which workspace they belong to. This only makes sense for users who work with more than one P4 repo. I will name my workspace “main” and the root will be “D:\p4\Assembla_demo”
9. Now we need to select a Stream. Click on “Browse...” The right of "Stream:" on the screen shown above. Then, select the Mainline.
10. It should look like this:
11. Click on OK. It will ask you if you want to choose a different location, click on No.
12. Now you are ready to start working! It should like the picture below. Compare it with the one in Step 8. Now you have the main (mainline) in your dropdown, which is where you will be committing your files.
13. Let’s add a file and commit it. Create a file in your folder and you will see it under Workspace:
14. Select the file you want to add and click on Add. It will ask you to "select pending changelist", just click on OK and your file will be added to the commit list.
15. You know a file is added because it has the red cross on the icon. Now click on Submit.
16. It will ask you to enter a description. This is used to let other users know what you are working on, like a summary of your changes. You can also relate your commits with a ticket you are working on in Assembla using the syntax "re #ticket_number":
17. Click on Submit and you will know the file has been submitted to your Assembla P4 repo because it has a green dot on its icon:
18. Finally, go to your P4 repo in Assembla and you will see your file in your main stream!
If you have any questions or need our assistance, don't hesitate to contact us at email@example.com.