Jump to content

Team Development


Luke Solar
 Share

Recommended Posts

Hello All!

I would like to ask you how you manage to work in a team on a processwire project. This also applies to the case when you develop on different machines (e.g. laptop on the train and desktop office pc).

For example: two different developers create 2 templates with various fields, then they push/commit their changes to a repository. both can update and merge the changes. but: to make the fields and templates available in the backend you still would have to add the database entries to the "fields" and "template" tables, right?

What are solutions and best practices for team development?

Thank you and keep on wiring!

  • Like 1
Link to comment
Share on other sites

Planning!

Hi Luke

I am a great believer that what ever system you are working on you should only be creating the fields and so on once you have already decided exactly what is needed.

With ProcessWire, since you create the templates and fields directly in the back end (as opposed to the template file which you will use for all your presentation work), this is particularly important, since you will want to make sure that you are not duplicating fields unnecessarily.

For instance, if you create a particular textarea/tinymce field, you may want to re-use that on several templates across your site. 

Once that work is done, then the people involved have a much better idea what template files they will be creating and what they will need them to do, and that work can then be delegated to team members.

Joss

Link to comment
Share on other sites

I think that traditional version control with Git or the equivalent is great for template files, front-end development files and your own custom modules. When it comes to defining the templates and fields on the admin side, it's better to do this from the admin rather than migrating SQL queries or the like. So someone in your team should be the gatekeeper for these administration resources.

  • Like 3
Link to comment
Share on other sites

"So someone in your team should be the gatekeeper for these administration resources."

Yep, always keep someone around who can take all the blame. 

My dog has a very rough time in that regard.

  • Like 3
Link to comment
Share on other sites

I'd agree with the above.

You would almost want to give your template developers naming conventions for fields and a list of fields currently available, then whoever is managing the backend receives the new templates with a list of any new fields they need to create.

Once the fields are there you can drop the templates in and they'll just work :)

It is possible to work this way even without a local database when people are proficient with the API, but the problem is when you get a larger team and how someone has set up a field locally isn't necessarily the same way the person managing the backend does it. I suppose if you had a site that big some sort of field settings exporter would be nice.

Link to comment
Share on other sites

Hello Wirecommunity!

Thanks for your answers. 

I only partly agree with "someone in your team should be the gatekeeper for these administration resources". While thats definitly true that someone (or a part of the team) should plan the database and architecture, change is unavoidable and even welcome nowadays in agile dev. When you change the name of a Field in the Object Model (when using a ORM) or Database (when using direct db access or xml) this change should easily be propageted to all teammembers/servers. Don't you think so?

Second point: If I make a fieldtype "location" locally including lat/lng then I have to go (manually) to all installations and add the field via the backoffice? atm I'm just synching the whole db every time I switch from laptop to PC but that would be impossible when a teammember joins me. I mean the whole thing is planned but the implementation should be done simultaneously in the end. 

I will - for now - sync the db. For the team there will be a documentation how the different field names for each template are. BTW ryan, regarding the creation of fields (and structure data) what tables should be synched? I just wanted to open a discussion for best practices here - Thanks for your feedback and any further comments.

good processing, have a nice day!

Link to comment
Share on other sites

Since each field is its own table, I would sync any beginning with "field_" as well as fieldgroups, fieldgroups_fields, fields and templates as a minimum (which is actually the vast majority of them).

If you're developing a site where permissions will change a lot then you'll probably want page_access too.

Link to comment
Share on other sites

There has been a lot of discussion about this. On mobile so cannot search. Mindplay was even starting about building a a module to solve this issue.

Template export/import will definitely help this.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By thmsnhl
      Hi everybody,
      we started our first Processwire driven project in my new company and for the first time, I was working on one site with more than 2 colleagues on the same site.
      It didn't take long for us to stumble across some problems when multiple developers work at the same time, conflicts with updating the database on vagrant machines, like duplicate entries for page IDs, errors when setting up fields and stuff like this. We ended up working on a dedicated database server, that we linked to our vagrant machines and most of the problems were gone, but the performance of this constellation is really bad compared to our first approach with database running on vagrant machines.
      I already tried to find a solution in the forums but I couldn't find anyone with problems like this.
      So I was wondering: how do you manage projects with multiple developers on vagrant machines in a git-based workflow?
    • By dst81
      Hi,
      I'm a System Administrator responsible for DevOps in our Company. We're trying PW in a single client project atm and experience some glitches with DevOps-/Workflow.
      We have a small team of developers that need to work with the same code base. They all need to be able to develop locally and deploy to a preview/staging environment.
      Our Toolstack contains git for versioning, chef/vagrant or docker for local development/testing and Jenkins for building assets and automatic deployment to the staging-site.
      There's several challenges / glitches in this process that makes me think that ProcessWire hadn't been developed for a use case like ours and is much more intended to be used by single developers that work right on the production system.
      Can you advise me on a suitable workflow?

      There's problems with the assets/files dir that must be shared between the staging website and local environments of our developers.
      We're right now working with symlinks on the staging system that helps to preserve the direcory when deploying from the master branch. but now we tend to use nfs-shares so devs can collaborate with a shared directory.

      The local docker containers can use the same target (the nfs) from inside the containers. But is that the way it needs to be done? Really?
      There's so much work that needs to be done to fit ProcessWire in a DevOps Workflow that we tend to decide to switch to another CMS.
       
      Any suggestions or hints that i might have missed. Am I wrong or is PW really not meant to be used this way. I
    • By louisstephens
      I was going to start working on a new site for myself and wife (a new hobby we have taken up), and had decided to try out Runcloud and Digital Ocean. I got my drop set up on digital ocean, as well as setting up various hooks/databases etc between github and run cloud. However, now I have hit a wall. 
      I cloned my "blank" repository into my local host (managed through MAMP) and dropped in a fresh install of PW, but now I have no idea of how to move forward. Is it best to just work locally, and then push this into a branch, and when ready, change branches and commit all to run cloud? Run cloud gives me an IP address to use for the database, but I can't get my localhost setup to recognize (I just get "Connection refused"). I am also unsure how to actually get my commits to push to run cloud, and handling the new set up.
      I am probably in over my head, but I thought I would try something new as a good learning experience. However, now I am just drowning  . Hopefully someone has some ideas on how to approach this, as I am very eager to get under way.
    • By Barry
      I'm attempting to deploy my site via GIT from bitbucket through Runcloud. I've managed to connect the repo via a webhook and I'm able to pull whenever I commit from local, but I keep getting a "Targetted directory /home/runcloud/webapps/domainname is not a GIT directory inside Web Application thedjcompany"
      I've always deployed via a GUI but we've moved servers and I'm very experienced with GIT, nor do I have any experience with Runcloud, so I'm hoping someone here has some info and can point me in the right direction?
      I'm guessing that I have to initiate the GIT folder within the webapp folder itself but I wouldn't know the command line to get that started.
      Any info/advise would be very appreciated
    • By benbyf
      Hey,
      Been using this starter theme for a little while now and thought I'd open it up on github - https://github.com/benbyford/bb-starter
      It has all my favourite modules installed, .less, some hany .js libraries and a set of blog templates for a simple news / blog setup. The theme is built on the simple theme from PW with additional setup. For more info see the Readme.md file on github.
      See it here - http://bbstarter.nicegrp.com/
      Thanks everyone for your continued work and fun using PW.
×
×
  • Create New...