<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Diogo Leitão</title>
    <description>The latest articles on DEV Community by Diogo Leitão (@diogoleitao).</description>
    <link>https://dev.to/diogoleitao</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F130683%2F8cb18144-7f56-4f57-836e-31bcf61b86a8.jpeg</url>
      <title>DEV Community: Diogo Leitão</title>
      <link>https://dev.to/diogoleitao</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/diogoleitao"/>
    <language>en</language>
    <item>
      <title>To merge or to rebase: that is the question</title>
      <dc:creator>Diogo Leitão</dc:creator>
      <pubDate>Tue, 16 Apr 2019 15:17:50 +0000</pubDate>
      <link>https://dev.to/runtime-revolution/to-merge-or-to-rebase-that-is-the-question-1jai</link>
      <guid>https://dev.to/runtime-revolution/to-merge-or-to-rebase-that-is-the-question-1jai</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--v4TtskRS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn-images-1.medium.com/max/1024/0%2AB8N2nz2sDy_-AM2k" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--v4TtskRS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn-images-1.medium.com/max/1024/0%2AB8N2nz2sDy_-AM2k" alt=""&gt;&lt;/a&gt;Photo by &lt;a href="https://unsplash.com/@garciasaldana_?utm_source=medium&amp;amp;utm_medium=referral"&gt;Pablo García Saldaña&lt;/a&gt; on &lt;a href="https://unsplash.com?utm_source=medium&amp;amp;utm_medium=referral"&gt;Unsplash&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It’s one of the eternal questions that ignite all dev discussions, on par with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Tabs vs Spaces&lt;/li&gt;
&lt;li&gt;Statically typed vs Dynamically typed&lt;/li&gt;
&lt;li&gt;Han Solo vs Greedo&lt;/li&gt;
&lt;li&gt;Jacob vs Edward&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;To make things simpler, I’m going to use an analogy. Let’s step away from code and programming for a while.&lt;/p&gt;

&lt;h3&gt;
  
  
  Integrating a paper research team
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;You recently integrated a group of people who are working on a big article or thesis. As you can imagine, you won’t do all the work and neither will the rest of your team. The work will be divided into fairly equal parts, so that each member of the team can focus on their branch of work.&lt;/li&gt;
&lt;li&gt;A given member of your team is the lead researcher. This means that their decisions and comments carry more weight; in case of a draw, they are the ones who have the final say. Therefore, we can say that your lead researcher’s work is the source of your truth.&lt;/li&gt;
&lt;li&gt;You have been assigned a new chapter on the research. You Google some existing papers on the subject (based on the main research document), find some images, plot some graphs, draw some conclusions, etc. A few days later, the lead researcher says some other colleague finished their part of the work and that piece has been merged into the main document (which, as I mentioned earlier, is your source of truth).&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--_MNqlUho--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn-images-1.medium.com/max/1024/0%2Aj1P7vX5MnDq89jQa" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--_MNqlUho--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn-images-1.medium.com/max/1024/0%2Aj1P7vX5MnDq89jQa" alt=""&gt;&lt;/a&gt;Photo by &lt;a href="https://unsplash.com/@jontyson?utm_source=medium&amp;amp;utm_medium=referral"&gt;Jon Tyson&lt;/a&gt; on &lt;a href="https://unsplash.com?utm_source=medium&amp;amp;utm_medium=referral"&gt;Unsplash&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;How should you continue your work from now on? How will you incorporate the newest additions into the research you’ve done so far? What if it clashes with what you currently have? Since the main document is your source of truth, you know it was approved by your peers and by the lead researcher, so you have to do you work starting from there!&lt;/p&gt;

&lt;h3&gt;
  
  
  Adding new information / Getting updates
&lt;/h3&gt;

&lt;p&gt;How you think it will happen:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--_oLgUiXO--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn-images-1.medium.com/max/320/1%2AYD5uNhM9JRtwXNnFiy0oQw.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--_oLgUiXO--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn-images-1.medium.com/max/320/1%2AYD5uNhM9JRtwXNnFiy0oQw.gif" alt=""&gt;&lt;/a&gt;Zipper gif @ &lt;a href="https://giphy.com/gifs/cgi-FS2GiqcNGT292"&gt;&lt;/a&gt;&lt;a href="https://giphy.com/gifs/cgi-FS2GiqcNGT292"&gt;https://giphy.com/gifs/cgi-FS2GiqcNGT292&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;How it will most likely happen (with fewer deaths and injuries, hopefully):&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Kmlh8ZD3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn-images-1.medium.com/max/480/1%2AkHykMUvIrwn2w8pXGdYPfg.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Kmlh8ZD3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn-images-1.medium.com/max/480/1%2AkHykMUvIrwn2w8pXGdYPfg.gif" alt=""&gt;&lt;/a&gt;Git Merge GIF @ &lt;a href="https://tenor.com/view/git-merge-gif-5920259"&gt;&lt;/a&gt;&lt;a href="https://tenor.com/view/git-merge-gif-5920259"&gt;https://tenor.com/view/git-merge-gif-5920259&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Before the &lt;em&gt;YOU’RE A REBASE PURIST&lt;/em&gt; accusations start pouring in, let me say that git merge has its advantages (of course it does!), the same way that git rebasehas its disadvantages. People who’ve been through it know that solving merge conflicts is easier and a lot less cumbersome when you use git merge.&lt;/p&gt;

&lt;p&gt;However, what I want to focus is not which one is better, but rather which should be used in which situations.&lt;/p&gt;

&lt;p&gt;Going back to the research paper analogy, once you get the updated version of the main document, &lt;em&gt;rebasing&lt;/em&gt; your work on it will produce a more coherent work. If you were to merge everything together, you’d probably end up with clashing definitions and mixed up pages (if you started your work on page 20, and the latest document has 23 pages, your work does not belong on page 20 — the same way your commits will be spliced in-between the main branch’s commits).&lt;/p&gt;

&lt;p&gt;Furthermore, when checking the log, we will see changes on both sides (main branch and our branch). If we place our changes on top of the most recent commit, there’ll be a straight line detailing in which order everything was done, and so we end up with a more coherent and clearer log history (and we don’t have to read through all the Merge branch develop into dl/feat-123/example commit messages as well).&lt;/p&gt;

&lt;h3&gt;
  
  
  Merging your research back into the main document
&lt;/h3&gt;

&lt;p&gt;Now that you have your work sorted out and cleaned up, it’s time for the final review before &lt;em&gt;merging&lt;/em&gt; it into the main document. By doing this, the moment your work was added to the main research will stand out, because everyone will know when what you did was introduced.&lt;/p&gt;

&lt;h3&gt;
  
  
  Back to code
&lt;/h3&gt;

&lt;p&gt;I think that most of what I explained before was self-explanatory. Either way, here’s a quick recap, with code:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;You’re added to a repo&lt;/li&gt;
&lt;li&gt;Someone assigns you a feature (let’s assume the main branch is develop)&lt;/li&gt;
&lt;li&gt;Someone updates develop, so you should rebase your branch&lt;/li&gt;
&lt;li&gt;Once you’re finished, open a pull request, get your code reviewed, and merge it into develop&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Summing everything up
&lt;/h3&gt;

&lt;p&gt;If in the future you have any doubts about whether you should merge or rebase, remember the following:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Always rebase from parent branch: this way your work will always be on top of the most up-to-date version of the work (and you avoid having multiple merge commits, keeping you branch history cleaner and clearer)&lt;/li&gt;
&lt;li&gt;Always merge into parent branch: when you merge your branch, you will know when that was done, since there will be a merge commit stating it!&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Whether it’s frontend, backend, mobile or DevOps, at Runtime Revolution we have a spot for you!&lt;/p&gt;




</description>
      <category>git</category>
      <category>gitflow</category>
      <category>productivity</category>
      <category>discuss</category>
    </item>
    <item>
      <title>Game DLCs look a lot like software releases, trust me</title>
      <dc:creator>Diogo Leitão</dc:creator>
      <pubDate>Mon, 21 Jan 2019 10:19:06 +0000</pubDate>
      <link>https://dev.to/runtime-revolution/game-dlcs-look-a-lot-like-software-releases-trust-me-3bjg</link>
      <guid>https://dev.to/runtime-revolution/game-dlcs-look-a-lot-like-software-releases-trust-me-3bjg</guid>
      <description>&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F800%2F1%2Ak2HazjmSASrVMYKIMkzQ7A.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F800%2F1%2Ak2HazjmSASrVMYKIMkzQ7A.jpeg"&gt;&lt;/a&gt;Photo on &lt;a href="https://visualhunt.com/photo/3169/" rel="noopener noreferrer"&gt;Visualhunt&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Did you ever stop to think that a game’s downloadable content (commonly known in the game industry as DLC) and the overall game development scene currently have a lot in common with software development? No? Well, let me tell you all about it!&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Game development: an extremely abridged summary of its history&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Game development used to be well thought out, designed from beginning to end, with intensive weeks of testing and fine tuning, bug fixing, and all the things you’d expect from a software company. Then, the game hits the stores, everyone buys it, it gets good reviews, happy customers, happy company.&lt;/p&gt;

&lt;p&gt;In the last 5 years or so, the video game industry has seen a major change in its time-to-market. Fans and &lt;em&gt;aficionados&lt;/em&gt; demanded that games be released as soon as possible since they are way too eager to try them out and beat all 500 levels in 20 different difficulty settings (your mileage may vary).&lt;/p&gt;

&lt;p&gt;But that’s the customer side of things. What happened on the product/development side? If the customer demands it, we must deliver! Right? Well, that’s where things started to go wrong…&lt;/p&gt;

&lt;p&gt;When some game studios decided to go down that road, it was well expected that some cracks would start showing. Let’s consider the following scenario:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The final deadline is in 3 weeks&lt;/li&gt;
&lt;li&gt;You and your team have 30 tasks/features to do&lt;/li&gt;
&lt;li&gt;You have estimated that this deadline is a bit tight for all the development (and testing!), but you can pull it off&lt;/li&gt;
&lt;li&gt;Then, PR/Sales chimes in and says: “Guys, we really need to have this ready in 1 week, at most!”&lt;/li&gt;
&lt;li&gt;&lt;em&gt;chaos ensues&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Some video games faced this exact type of situation, due to which they ended up getting bad reviews because of bad graphics (cinematic vs. in-game footage), plot holes, bad animations, buggy controls, etc. What the companies ended doing was releasing bug fixes and all the missing features as DLC, which contradicts what DLCs are: new game content!&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Software development&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Can you see how this relates back to your project? On the first meeting with the client everyone gets to know the project: scope, main features, obstacles that may arise when developing, the usual stuff. Based on this, you and your team outline a roadmap with sprints or a list of checkpoints, whatever flavour of project management you prefer. But one thing has to be set in stone: the deadline. The deadline should be a fixed date, far off in the future, and it is advised that the week before the deadline no major feature or redesign is implemented, since this has a huge cost on tracking down new bugs and testing the application end-to-end.&lt;/p&gt;

&lt;p&gt;So, what can you do when the client wakes up one morning and says “This needs to be ready next week”, when it was supposed to be ready in three? Neither of the following answers are satisfactory (for you or the client), but here they are:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cut down on project scope — let’s face it: it’s extremely hard to accomplish in 1 week what you had planned to do in 3. So, the easy thing to do is cut down on features. It’s better to have 15 fully working features than 30 somewhat-working-but-only-on-a-given-scenario features. The client may not like that the project doesn’t have all the sparkly stuff they wanted, but at least it won’t crash during the live demos.&lt;/li&gt;
&lt;li&gt;Push the deadline forward — this is what may first come to mind when approaching the original deadline and acknowledging you can’t make it (&lt;em&gt;if only I had more time…&lt;/em&gt;). This is hard to discuss, because now the client has to rethink their marketing strategy and PR stuff, as they have announced their project would go live sooner than expected. If they stick to this idea, then you’re gonna end up in a situation similar to one from the previous solution (30 buggy features vs. 15 working features).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If, however, you end up releasing the product as scheduled by the client without any changes regarding which features are included and feature completeness, then you’re probably going to be creating DLC-like updates, finishing up on your previous work and fixing bugs all the time.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;None of the solutions presented above are ideal, nor should they be applied at all times as if they were a panacea. Feature status and deadlines should be something you discuss with the client regularly, to keep them informed on how far ahead/behind schedule you are, and to keep you informed of any schedule or feature changes on their side.&lt;/p&gt;

&lt;p&gt;Whether it’s frontend, backend, mobile or DevOps, at Runtime Revolution we have a spot for you!&lt;/p&gt;




</description>
      <category>softwarelifecycle</category>
      <category>softwaredevelopment</category>
      <category>projectmanagement</category>
      <category>gamedev</category>
    </item>
  </channel>
</rss>
