SlideShare a Scribd company logo
1 of 46
Building Foundations
MITCHELL MATTHEWS
• There will be a slide with links and a QR code at the end of the
presentation
Save Photos Until the End
SuprTEK Advanced Technology Group 2
• Version control
• Core documentation
• Project structure
• Code modularization
• Good frameworks and libraries
• Fast, simple builds
• Thorough testing
Components of a Successful Project
SuprTEK Advanced Technology Group 3
Version Control
SuprTEK Advanced Technology Group 4
• Project history
• Disaster prevention
• Reduced clutter
• Smaller footprint
• Faster navigation
The Benefits of Version Control
SuprTEK Advanced Technology Group 5
• Easy collaboration and contributions
• Ability to access your code wherever you have an internet connection
• Free backups
These sites are popular for hosting repositories:
• BitBucket
• GitHub
• GitLab
Host Your Repositories
SuprTEK Advanced Technology Group 6
• Help other developers figure out what you’re doing
• Good commit messages are:
• Short
• Descriptive
• Consistent
• Conventions vary by version control system
• Look them up and follow them
Commit Messages
SuprTEK Advanced Technology Group 7
• Maintains correct dependencies between projects
• Keeps a clear list of when fixes or bugs occurred
• Allows stable versions to be accessed with ease
Tagging and Versioning
SuprTEK Advanced Technology Group 8
The Basics
SuprTEK Advanced Technology Group 9
• A license file contains the text for the license your code is released
under
• Developers will not contribute to a project with no license
• Spend a few minutes (or more) to decide upon a license
• Licenses are often not compatible with certain projects; choose one that
makes sense for your current use
• You can read up on software licenses here: https://tldrlegal.com/
Create a LICENSE File
SuprTEK Advanced Technology Group 10
• README files are displayed by default by most repository hosts
• Developers will go to a readme file before anything else
• READMEs should include:
• Basic download/use instructions
• Compilation instructions
• Limitations or prerequisites (“Only runs on Windows” or “Requires JDK 1.8”)
• Other useful sections include:
• Project structure
• Links to more detailed resources (Wikis, FAQs, Issue Trackers, etc)
Create a README File
SuprTEK Advanced Technology Group 11
• When a project becomes large enough, a contribution guide sets a
standard for all developers to follow
• It should detail:
• Code style
• Branching and merging guidelines
• Naming conventions
• Anything else you feel contributors should know
Build a Contribution Guide
SuprTEK Advanced Technology Group 12
• Change logs are great for non-contributors
• Tracks features and bug fixes present in each release
• Can serve as a short-term roadmap for upcoming features
Keep a Change Log
SuprTEK Advanced Technology Group 13
• Make a design document available
• Provide a roadmap for short and long-term goals
• Use an issue tracker, checklist, the back of your hand to stay on
track
• Link to these documents/sites in the readme or contribution guide
Plan for the Future
SuprTEK Advanced Technology Group 14
Project Structure
SuprTEK Advanced Technology Group 15
Following conventions helps other developers familiarize themselves
with your code much faster.
Be particularly mindful of:
• Source folders
• Resource folders
• Test folders
• Dependency folders
Follow Language Conventions
SuprTEK Advanced Technology Group 16
• Place core documentation in the repository root
• These core files include:
• Readmes
• Change logs
• Contribution guides
• License files
• All other documentation should have dedicated folders
Separate Documentation
SuprTEK Advanced Technology Group 17
• Anything you build or compile should be hosted elsewhere
• Binaries add bloat to repositories
Don’t Include Binaries
SuprTEK Advanced Technology Group 18
• Modularizing your code makes it easier to find what you want in
larger projects
• It also helps in keeping reusable code in one place
Modularize Your Code
SuprTEK Advanced Technology Group 19
Modularizing Code
SuprTEK Advanced Technology Group 20
If your code is public:
• Keep your projects that work together in the same repository
• If necessary, create a library as a separate project and publish it
Keep it Together
SuprTEK Advanced Technology Group 21
If you have multiple applications that don’t depend on each other:
• Make these their own repositories
• If your project is large enough, consider starting a group or
organization on your repository host
If your code is private:
• Split major components into their own repositories
• Make sure they still build on their own
Keep it Apart
SuprTEK Advanced Technology Group 22
• These are areas of code that appear in multiple places
• Usually in the form of:
• Interfaces
• Abstract classes
• Plain data objects
• Helpers and utilities
• Database access layers
• Multiple common modules can exist if needed
Identify Common Functionality
SuprTEK Advanced Technology Group 23
• Utilize modules or sub-projects to separate code that’s common
across multiple areas of functionality
• For example:
• A ‘common’ module containing interfaces
• A ‘database’ module that implements the interfaces in the ‘common’ module
• A ‘server’ module that uses the ‘common’ and ‘database’ modules—the ‘database’ module’s
implementations are injected by the application server
Create Sub-Projects or Modules
SuprTEK Advanced Technology Group 24
Application
Server
Server
Module
Database
Module
Database
Module
Server
Module
Injected IntoInterfaces
Frameworks and Libraries
SuprTEK Advanced Technology Group 25
• Use well-known, popular frameworks and libraries
• Odds are, they’re popular for a good reason
• Other developers are more likely to be familiar with more popular
libraries
Go With the Flow
SuprTEK Advanced Technology Group 26
• Making developers learn new libraries slows their contributions
• These libraries may have obscure bugs or poor performance
• They may not be updated if future compatibility issues arise
• Bugs may never get fixed
Don’t Pick Obscure Frameworks/Libraries
SuprTEK Advanced Technology Group 27
• Sometimes a new or obscure library can fit your needs better than
anything else
• Try it out and see!
…Except When You Should
SuprTEK Advanced Technology Group 28
• Larger dependencies means longer downloads
• Large downloads are painful when working on a slow connection or one with
data caps
• Size limitations may exist on some targeted platforms
• An 11MB localization library may not be a lot until you’re limited to a 50MB
Android package
• The benefit of a library may not outweigh the extra space
• Consider if you need a library before adding it to your projects
Be Mindful of the Size of Dependencies
SuprTEK Advanced Technology Group 29
Packaging Dependencies
SuprTEK Advanced Technology Group 30
Don’t Do It!
SuprTEK Advanced Technology Group 31
• Keep them all in a single location, preferably near the root of your
directory structure
• Provide detailed instructions for installing them
• If your project targets multiple platforms, ensure the dependencies
are included for each platform
…But If You Must
SuprTEK Advanced Technology Group 32
• Dependency managers download and inject dependencies
automatically
• They enforce versions and sub-project inheritance
• You can get back to writing code faster instead of configuring paths
and build tools
Use a Dependency Manager
SuprTEK Advanced Technology Group 33
Make Builds Easy
SuprTEK Advanced Technology Group 34
• Only a few commands (at most) should be necessary to build a
project
• If this is not possible to do, consider creating scripts or using
different build tools
• Keep the time to download, build, and run a project for the first
time under 15 minutes
• Don’t require other dependencies to be compiled or installed—
especially outside of a project
• If other modules in the same project are required, include those in
the build process automatically
Keep it Simple
SuprTEK Advanced Technology Group 35
• A build should not require configuration outside the project
• Requiring outside configuration vastly decreases build compatibility
with other systems
• Sometimes this is unavoidable, depending on the language and
dependencies
• Attempt to minimize this configuration
System Configuration is Bad
SuprTEK Advanced Technology Group 36
• A build should produce a usable (runnable or deployable) artifact
when complete
• Requiring further manual steps to use an artifact wastes time and
frustrates developers
Create Something Useful
SuprTEK Advanced Technology Group 37
Testing Things Out
SuprTEK Advanced Technology Group 38
• Borrow a friend’s
• Ask a friend to try things out
• Fire up a virtual machine
• Use a free Amazon Web Services account
• Wait for complaints to accumulate in your issue tracker
Build on a Clean System
SuprTEK Advanced Technology Group 39
• If a project targets multiple platforms, perform a build on each one
• Follow your build steps precisely and update documentation when
needed
Test Other Operating Systems
SuprTEK Advanced Technology Group 40
• Many build tools automate testing
• Core functionality needs to be tested; other tests should be
optional
• Avoid platform-specific tests if possible
• Allow manual running of tests
• Run all tests (including optional ones) before performing a release
Include Tests in Build Process
SuprTEK Advanced Technology Group 41
• Don’t let a build pass when it fails tests
• This prevents accidentally releasing buggy code
• If the build process fails due to a bad test, fix it or remove it in a
timely manner
…And Fail the Build When the Tests Do
SuprTEK Advanced Technology Group 42
• Deploy or run projects on every platform it’s targeted for
• Ensure functionality is present and the same for each platform
• Document any extra steps taken for deploying
Deploy, then Deploy Again
SuprTEK Advanced Technology Group 43
Your repository should now be:
• Accessible
• Maintainable
• Well-organized
Pat Yourself on the Back for a Job Well Done
SuprTEK Advanced Technology Group 44
Download:
http://www.slideshare.net/MitchellMatthews/building-foundations
The Photo Slide
SuprTEK Advanced Technology Group 45
My GitHub Account: https://github.com/KrazyTheFox
• Explore, evaluate, and develop new technologies that
can be applied to our clients’ missions
Research & Product
Development
• Apply capabilities from R&PD to develop solutions that
solve client-specific problems
Solutions
Architectures
• Provide tactical consulting services to address
technically-challenging requirements on client programsConsulting Services
• Optimize and maintain IT infrastructure and security to
support and enhance business operationsIT Infrastructure
Building Stuff Our Clients Wish Existed…

More Related Content

What's hot

LV Dev Efficiency NIDays 2015
LV Dev Efficiency NIDays 2015LV Dev Efficiency NIDays 2015
LV Dev Efficiency NIDays 2015
Jeffrey Habets
 
CM10.2 Power Builder Source Control
CM10.2 Power Builder Source ControlCM10.2 Power Builder Source Control
CM10.2 Power Builder Source Control
Eric Saperstein
 

What's hot (20)

Jfrog artifactory artifact management c tamilmaran presentation - copy
Jfrog artifactory artifact management c tamilmaran presentation - copyJfrog artifactory artifact management c tamilmaran presentation - copy
Jfrog artifactory artifact management c tamilmaran presentation - copy
 
Experience in teaching devops
Experience in teaching devopsExperience in teaching devops
Experience in teaching devops
 
Packaging tool options
Packaging tool optionsPackaging tool options
Packaging tool options
 
Deployability
DeployabilityDeployability
Deployability
 
7 Source Control and Release Management
7 Source Control and Release Management7 Source Control and Release Management
7 Source Control and Release Management
 
Dev ops and safety critical systems
Dev ops and safety critical systemsDev ops and safety critical systems
Dev ops and safety critical systems
 
OpenCms Module Development & Deployment with IntelliJ, Maven and Jenkins
OpenCms Module Development & Deployment with IntelliJ, Maven and JenkinsOpenCms Module Development & Deployment with IntelliJ, Maven and Jenkins
OpenCms Module Development & Deployment with IntelliJ, Maven and Jenkins
 
Flight East 2018 Presentation–A DevOps State of Mind: Continuous Security wit...
Flight East 2018 Presentation–A DevOps State of Mind: Continuous Security wit...Flight East 2018 Presentation–A DevOps State of Mind: Continuous Security wit...
Flight East 2018 Presentation–A DevOps State of Mind: Continuous Security wit...
 
PHP Unconference Continuous Integration
PHP Unconference Continuous IntegrationPHP Unconference Continuous Integration
PHP Unconference Continuous Integration
 
Aiming for automatic updates - Drupal Dev Days Lisbon 2018
Aiming for automatic updates - Drupal Dev Days Lisbon 2018Aiming for automatic updates - Drupal Dev Days Lisbon 2018
Aiming for automatic updates - Drupal Dev Days Lisbon 2018
 
NI Package Manager
NI Package ManagerNI Package Manager
NI Package Manager
 
DevOps Service | Mindtree
DevOps Service | MindtreeDevOps Service | Mindtree
DevOps Service | Mindtree
 
CA Harvest "Private Solutions - State of New Hampshire
CA Harvest "Private Solutions - State of New HampshireCA Harvest "Private Solutions - State of New Hampshire
CA Harvest "Private Solutions - State of New Hampshire
 
BP-10 Keeping Your Sanity – Rapid Development & Deployment Tools
BP-10 Keeping Your Sanity – Rapid Development & Deployment ToolsBP-10 Keeping Your Sanity – Rapid Development & Deployment Tools
BP-10 Keeping Your Sanity – Rapid Development & Deployment Tools
 
LV Dev Efficiency NIDays 2015
LV Dev Efficiency NIDays 2015LV Dev Efficiency NIDays 2015
LV Dev Efficiency NIDays 2015
 
Building Applications Using the U2 Toolkit for .NET
Building Applications Using the U2 Toolkit for .NETBuilding Applications Using the U2 Toolkit for .NET
Building Applications Using the U2 Toolkit for .NET
 
CM10.2 Power Builder Source Control
CM10.2 Power Builder Source ControlCM10.2 Power Builder Source Control
CM10.2 Power Builder Source Control
 
Single Source of Truth in a Distributed World by Sven Erik Knop
Single Source of Truth in a Distributed World by Sven Erik KnopSingle Source of Truth in a Distributed World by Sven Erik Knop
Single Source of Truth in a Distributed World by Sven Erik Knop
 
SLTS kernel and base-layer development in the Civil Infrastructure Platform
SLTS kernel and base-layer development in the Civil Infrastructure PlatformSLTS kernel and base-layer development in the Civil Infrastructure Platform
SLTS kernel and base-layer development in the Civil Infrastructure Platform
 
Git SVN Migrate Reasons
Git SVN Migrate ReasonsGit SVN Migrate Reasons
Git SVN Migrate Reasons
 

Similar to Building foundations

Why It’s Important to Contribute to Open-Source Projects | Keysight Connect #10
Why It’s Important to Contribute to Open-Source Projects | Keysight Connect #10Why It’s Important to Contribute to Open-Source Projects | Keysight Connect #10
Why It’s Important to Contribute to Open-Source Projects | Keysight Connect #10
IxiaRomania
 

Similar to Building foundations (20)

Plug-ins & Third-Party SDKs in UE4
Plug-ins & Third-Party SDKs in UE4Plug-ins & Third-Party SDKs in UE4
Plug-ins & Third-Party SDKs in UE4
 
Continuous Integration
Continuous IntegrationContinuous Integration
Continuous Integration
 
License compliance in embedded linux with the yocto project
License compliance in embedded linux with the yocto projectLicense compliance in embedded linux with the yocto project
License compliance in embedded linux with the yocto project
 
Open Source License Compliance with AGL
Open Source License Compliance with AGLOpen Source License Compliance with AGL
Open Source License Compliance with AGL
 
From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...
From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...
From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...
 
A Summary about Hykes' Keynote on Dockercon 2015
A Summary about Hykes' Keynote on Dockercon 2015A Summary about Hykes' Keynote on Dockercon 2015
A Summary about Hykes' Keynote on Dockercon 2015
 
Writing Services with ZF2
Writing Services with ZF2Writing Services with ZF2
Writing Services with ZF2
 
Advanced Internet of Things firmware engineering with Thingsquare and Contiki...
Advanced Internet of Things firmware engineering with Thingsquare and Contiki...Advanced Internet of Things firmware engineering with Thingsquare and Contiki...
Advanced Internet of Things firmware engineering with Thingsquare and Contiki...
 
Top 10 dev ops tools (1)
Top 10 dev ops tools (1)Top 10 dev ops tools (1)
Top 10 dev ops tools (1)
 
SQL Server DevOps Jumpstart
SQL Server DevOps JumpstartSQL Server DevOps Jumpstart
SQL Server DevOps Jumpstart
 
Why It’s Important to Contribute to Open-Source Projects | Keysight Connect #10
Why It’s Important to Contribute to Open-Source Projects | Keysight Connect #10Why It’s Important to Contribute to Open-Source Projects | Keysight Connect #10
Why It’s Important to Contribute to Open-Source Projects | Keysight Connect #10
 
Modern Web-site Development Pipeline
Modern Web-site Development PipelineModern Web-site Development Pipeline
Modern Web-site Development Pipeline
 
StarlingX - A Platform for the Distributed Edge | Ildiko Vancsa
StarlingX - A Platform for the Distributed Edge | Ildiko VancsaStarlingX - A Platform for the Distributed Edge | Ildiko Vancsa
StarlingX - A Platform for the Distributed Edge | Ildiko Vancsa
 
Good Practices for Developing Scientific Software Frameworks: The WRENCH fram...
Good Practices for Developing Scientific Software Frameworks: The WRENCH fram...Good Practices for Developing Scientific Software Frameworks: The WRENCH fram...
Good Practices for Developing Scientific Software Frameworks: The WRENCH fram...
 
Vs11 overview
Vs11 overviewVs11 overview
Vs11 overview
 
Security for devs
Security for devsSecurity for devs
Security for devs
 
Docker Global Hack Day #3
Docker Global Hack Day #3 Docker Global Hack Day #3
Docker Global Hack Day #3
 
Suguk Southampton CodePlex - March 2014
Suguk Southampton   CodePlex - March 2014Suguk Southampton   CodePlex - March 2014
Suguk Southampton CodePlex - March 2014
 
Sitecore development approach evolution – destination helix
Sitecore development approach evolution – destination helixSitecore development approach evolution – destination helix
Sitecore development approach evolution – destination helix
 
DevOps - IaC | Talk | AGILE GURUGRAM 2018 | 23 - 24 March, 2018
DevOps - IaC | Talk | AGILE GURUGRAM 2018 | 23 - 24 March, 2018DevOps - IaC | Talk | AGILE GURUGRAM 2018 | 23 - 24 March, 2018
DevOps - IaC | Talk | AGILE GURUGRAM 2018 | 23 - 24 March, 2018
 

Recently uploaded

%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
masabamasaba
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is inside
shinachiaurasa2
 
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
masabamasaba
 
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Medical / Health Care (+971588192166) Mifepristone and Misoprostol tablets 200mg
 
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
masabamasaba
 
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Medical / Health Care (+971588192166) Mifepristone and Misoprostol tablets 200mg
 
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
VictoriaMetrics
 

Recently uploaded (20)

%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benoni%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benoni
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is inside
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfPayment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
 
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
 
tonesoftg
tonesoftgtonesoftg
tonesoftg
 
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
 
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
 
Architecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastArchitecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the past
 
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
 
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
 
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
 
WSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go PlatformlessWSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go Platformless
 
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
 

Building foundations

  • 2. • There will be a slide with links and a QR code at the end of the presentation Save Photos Until the End SuprTEK Advanced Technology Group 2
  • 3. • Version control • Core documentation • Project structure • Code modularization • Good frameworks and libraries • Fast, simple builds • Thorough testing Components of a Successful Project SuprTEK Advanced Technology Group 3
  • 4. Version Control SuprTEK Advanced Technology Group 4
  • 5. • Project history • Disaster prevention • Reduced clutter • Smaller footprint • Faster navigation The Benefits of Version Control SuprTEK Advanced Technology Group 5
  • 6. • Easy collaboration and contributions • Ability to access your code wherever you have an internet connection • Free backups These sites are popular for hosting repositories: • BitBucket • GitHub • GitLab Host Your Repositories SuprTEK Advanced Technology Group 6
  • 7. • Help other developers figure out what you’re doing • Good commit messages are: • Short • Descriptive • Consistent • Conventions vary by version control system • Look them up and follow them Commit Messages SuprTEK Advanced Technology Group 7
  • 8. • Maintains correct dependencies between projects • Keeps a clear list of when fixes or bugs occurred • Allows stable versions to be accessed with ease Tagging and Versioning SuprTEK Advanced Technology Group 8
  • 9. The Basics SuprTEK Advanced Technology Group 9
  • 10. • A license file contains the text for the license your code is released under • Developers will not contribute to a project with no license • Spend a few minutes (or more) to decide upon a license • Licenses are often not compatible with certain projects; choose one that makes sense for your current use • You can read up on software licenses here: https://tldrlegal.com/ Create a LICENSE File SuprTEK Advanced Technology Group 10
  • 11. • README files are displayed by default by most repository hosts • Developers will go to a readme file before anything else • READMEs should include: • Basic download/use instructions • Compilation instructions • Limitations or prerequisites (“Only runs on Windows” or “Requires JDK 1.8”) • Other useful sections include: • Project structure • Links to more detailed resources (Wikis, FAQs, Issue Trackers, etc) Create a README File SuprTEK Advanced Technology Group 11
  • 12. • When a project becomes large enough, a contribution guide sets a standard for all developers to follow • It should detail: • Code style • Branching and merging guidelines • Naming conventions • Anything else you feel contributors should know Build a Contribution Guide SuprTEK Advanced Technology Group 12
  • 13. • Change logs are great for non-contributors • Tracks features and bug fixes present in each release • Can serve as a short-term roadmap for upcoming features Keep a Change Log SuprTEK Advanced Technology Group 13
  • 14. • Make a design document available • Provide a roadmap for short and long-term goals • Use an issue tracker, checklist, the back of your hand to stay on track • Link to these documents/sites in the readme or contribution guide Plan for the Future SuprTEK Advanced Technology Group 14
  • 15. Project Structure SuprTEK Advanced Technology Group 15
  • 16. Following conventions helps other developers familiarize themselves with your code much faster. Be particularly mindful of: • Source folders • Resource folders • Test folders • Dependency folders Follow Language Conventions SuprTEK Advanced Technology Group 16
  • 17. • Place core documentation in the repository root • These core files include: • Readmes • Change logs • Contribution guides • License files • All other documentation should have dedicated folders Separate Documentation SuprTEK Advanced Technology Group 17
  • 18. • Anything you build or compile should be hosted elsewhere • Binaries add bloat to repositories Don’t Include Binaries SuprTEK Advanced Technology Group 18
  • 19. • Modularizing your code makes it easier to find what you want in larger projects • It also helps in keeping reusable code in one place Modularize Your Code SuprTEK Advanced Technology Group 19
  • 20. Modularizing Code SuprTEK Advanced Technology Group 20
  • 21. If your code is public: • Keep your projects that work together in the same repository • If necessary, create a library as a separate project and publish it Keep it Together SuprTEK Advanced Technology Group 21
  • 22. If you have multiple applications that don’t depend on each other: • Make these their own repositories • If your project is large enough, consider starting a group or organization on your repository host If your code is private: • Split major components into their own repositories • Make sure they still build on their own Keep it Apart SuprTEK Advanced Technology Group 22
  • 23. • These are areas of code that appear in multiple places • Usually in the form of: • Interfaces • Abstract classes • Plain data objects • Helpers and utilities • Database access layers • Multiple common modules can exist if needed Identify Common Functionality SuprTEK Advanced Technology Group 23
  • 24. • Utilize modules or sub-projects to separate code that’s common across multiple areas of functionality • For example: • A ‘common’ module containing interfaces • A ‘database’ module that implements the interfaces in the ‘common’ module • A ‘server’ module that uses the ‘common’ and ‘database’ modules—the ‘database’ module’s implementations are injected by the application server Create Sub-Projects or Modules SuprTEK Advanced Technology Group 24 Application Server Server Module Database Module Database Module Server Module Injected IntoInterfaces
  • 25. Frameworks and Libraries SuprTEK Advanced Technology Group 25
  • 26. • Use well-known, popular frameworks and libraries • Odds are, they’re popular for a good reason • Other developers are more likely to be familiar with more popular libraries Go With the Flow SuprTEK Advanced Technology Group 26
  • 27. • Making developers learn new libraries slows their contributions • These libraries may have obscure bugs or poor performance • They may not be updated if future compatibility issues arise • Bugs may never get fixed Don’t Pick Obscure Frameworks/Libraries SuprTEK Advanced Technology Group 27
  • 28. • Sometimes a new or obscure library can fit your needs better than anything else • Try it out and see! …Except When You Should SuprTEK Advanced Technology Group 28
  • 29. • Larger dependencies means longer downloads • Large downloads are painful when working on a slow connection or one with data caps • Size limitations may exist on some targeted platforms • An 11MB localization library may not be a lot until you’re limited to a 50MB Android package • The benefit of a library may not outweigh the extra space • Consider if you need a library before adding it to your projects Be Mindful of the Size of Dependencies SuprTEK Advanced Technology Group 29
  • 31. Don’t Do It! SuprTEK Advanced Technology Group 31
  • 32. • Keep them all in a single location, preferably near the root of your directory structure • Provide detailed instructions for installing them • If your project targets multiple platforms, ensure the dependencies are included for each platform …But If You Must SuprTEK Advanced Technology Group 32
  • 33. • Dependency managers download and inject dependencies automatically • They enforce versions and sub-project inheritance • You can get back to writing code faster instead of configuring paths and build tools Use a Dependency Manager SuprTEK Advanced Technology Group 33
  • 34. Make Builds Easy SuprTEK Advanced Technology Group 34
  • 35. • Only a few commands (at most) should be necessary to build a project • If this is not possible to do, consider creating scripts or using different build tools • Keep the time to download, build, and run a project for the first time under 15 minutes • Don’t require other dependencies to be compiled or installed— especially outside of a project • If other modules in the same project are required, include those in the build process automatically Keep it Simple SuprTEK Advanced Technology Group 35
  • 36. • A build should not require configuration outside the project • Requiring outside configuration vastly decreases build compatibility with other systems • Sometimes this is unavoidable, depending on the language and dependencies • Attempt to minimize this configuration System Configuration is Bad SuprTEK Advanced Technology Group 36
  • 37. • A build should produce a usable (runnable or deployable) artifact when complete • Requiring further manual steps to use an artifact wastes time and frustrates developers Create Something Useful SuprTEK Advanced Technology Group 37
  • 38. Testing Things Out SuprTEK Advanced Technology Group 38
  • 39. • Borrow a friend’s • Ask a friend to try things out • Fire up a virtual machine • Use a free Amazon Web Services account • Wait for complaints to accumulate in your issue tracker Build on a Clean System SuprTEK Advanced Technology Group 39
  • 40. • If a project targets multiple platforms, perform a build on each one • Follow your build steps precisely and update documentation when needed Test Other Operating Systems SuprTEK Advanced Technology Group 40
  • 41. • Many build tools automate testing • Core functionality needs to be tested; other tests should be optional • Avoid platform-specific tests if possible • Allow manual running of tests • Run all tests (including optional ones) before performing a release Include Tests in Build Process SuprTEK Advanced Technology Group 41
  • 42. • Don’t let a build pass when it fails tests • This prevents accidentally releasing buggy code • If the build process fails due to a bad test, fix it or remove it in a timely manner …And Fail the Build When the Tests Do SuprTEK Advanced Technology Group 42
  • 43. • Deploy or run projects on every platform it’s targeted for • Ensure functionality is present and the same for each platform • Document any extra steps taken for deploying Deploy, then Deploy Again SuprTEK Advanced Technology Group 43
  • 44. Your repository should now be: • Accessible • Maintainable • Well-organized Pat Yourself on the Back for a Job Well Done SuprTEK Advanced Technology Group 44
  • 45. Download: http://www.slideshare.net/MitchellMatthews/building-foundations The Photo Slide SuprTEK Advanced Technology Group 45 My GitHub Account: https://github.com/KrazyTheFox
  • 46. • Explore, evaluate, and develop new technologies that can be applied to our clients’ missions Research & Product Development • Apply capabilities from R&PD to develop solutions that solve client-specific problems Solutions Architectures • Provide tactical consulting services to address technically-challenging requirements on client programsConsulting Services • Optimize and maintain IT infrastructure and security to support and enhance business operationsIT Infrastructure Building Stuff Our Clients Wish Existed…