SlideShare una empresa de Scribd logo
1 de 41
GitHub/git +GitHub/git +
CMake +CMake +
CLionCLion
GitGit
25.04.17 Igor Khokhriakov 3
Git
“Git was created by Linus Torvalds in 2005 for
development of the Linux kernel, with other kernel
developers contributing to its initial development.”
Wikipedia.org
According to StackOverflow survey 2017 ~70% of
developers are using git
25.04.17 Igor Khokhriakov 4
Key points about Git
● Strong support for non-linear development
– a core assumption is that a change will be merged more
often than it is written
● Distributed development
– Git gives each developer a local copy of the full
development history
● Efficient handling of large projects
– an order of magnitude faster than some version control
systems
GitHubGitHub
25.04.17 Igor Khokhriakov 6
GitHub
● Hosting that provides git service
● Suddenly became a central feature in git
ecosystem
– My personal experience is that back in 2012 they
did not have even in-line commit comment (vs
bitbucket)
25.04.17 Igor Khokhriakov 7
Summary
SourceForge/svn = GitHub/git
aka Hosting/repository
SourceForge/svn ≠ GitHub/git
GitHub provides tons of features and
integrations: travis, appveyor, read-the-
docs, ...
PRACTICEPRACTICE
25.04.17 Igor Khokhriakov 9
Git concept
● Simple case: one user; direct access to the remote repo
– Create new file:
25.04.17 Igor Khokhriakov 10
Git concept
– Working with branches:
● $> git branch my_branch
● $> git checkout my_branch
– Shortcut: git checkout -b my_branch
● Do stuff
● $> git push -u my_branch origin
– Merging branch into the master
● $> git checkout master
● $> git merge my_branch
25.04.17 Igor Khokhriakov 11
Git cheat sheet
http://files.zeroturnaround.com/pdf/zt_git_cheat_sheet.pdf
GitHub/git workflowGitHub/git workflow
25.04.17 Igor Khokhriakov 13
GitHub concept
● Contributing via Pull-Request (PR)
25.04.17 Igor Khokhriakov 14
GitHub concept
– Creating a Pull-Request
● GitHub fork
● $> git clone …
● $> git checkout -b feature
● Do stuff
● $> git push
● GitHub create a Pull-Request
● Do more pushes
25.04.17 Igor Khokhriakov 15
GitHub concept
– Rebasing onto master
● $> git pull –rebase upstream master
● $> git push
– Closing the PR
● maintainer(s) approval(s) + tests passed
● GitHub megre PR
● $> git branch -d feature
● Sync fork master (origin) with upstream master
– $> git checkout master; git pull upstream master
25.04.17 Igor Khokhriakov 16
gitk
25.04.17 Igor Khokhriakov 17
https://www.atlassian.com/git/tutorials
25.04.17 Igor Khokhriakov 18
Keep in mind
● Git is very powerful and flexible
– github.com/tango-controls/cppTango
● Merged 4 repositories
● Preserved commits history
● Preserved branches
Do not hesitate to google the
most astounding ideas
aka How can I do X in git
CMakeCMake
25.04.17 Igor Khokhriakov 20
CMake
● Cross-platform build automatization tool
● Declarative scripting language for managing
native projects
● Dependency management (via pkg-config or
cmake modules)
● Testing
● Packaging
25.04.17 Igor Khokhriakov 21
CmakeLists.txt
25.04.17 Igor Khokhriakov 22
Build using cmake
● $> mkdir build
● $> cd build
● $> cmake ..
● $> make
● $> make install
… better use IDE like CLion
25.04.17 Igor Khokhriakov 23
CMake guide lines
● Use the following directory structure:
– configure
– include
– docs
– src
– test
● Use dedicated project when configuration is totally different
from the root project
25.04.17 Igor Khokhriakov 24
CMake guide lines
● Split complex project into modules
– add_library(my_module OBJECT …)
● Use CTest for integration testing. Unit tests
must be independent
● Use CPack to generate packages and custom
targets to deploy them
– add_custom_target(COMMAND curl ...)
25.04.17 Igor Khokhriakov 25
Where get help?
● No good book :(
● Find some open-source project and explore it
– https://github.com/pni-libraries/libpnicore
– https://github.com/ufo-kit/ufo-core
● CMake itself... for gurus
CLionCLion
25.04.17 Igor Khokhriakov 27
25.04.17 Igor Khokhriakov 28
Agenda
● CMake support
● Navigation
● Refactoring
● Git integration
● Debugging
● Creating live templates
25.04.17 Igor Khokhriakov 29
CMake support
File → settings
OR
ctrl+alt+s
25.04.17 Igor Khokhriakov 30
CMake support
● Run targets
25.04.17 Igor Khokhriakov 31
Navigation
● Find class: ctrl+n
● Find file: ctrl+shift+n
● Subclasses:
● Implementation
&Override:
25.04.17 Igor Khokhriakov 32
Navigation
● Method lookup: ctrl+F12 OR structure tab
● Code navigation: ctrl+click on an item
● Find usages: Alt+F7
25.04.17 Igor Khokhriakov 33
Refactoring
● Rename: shift+F6
● Change signature: ctrl+F6
● Move entity: F6
● Generate definitions: ctrl+shift+d
● Generate … : alt+insert
● Generate constructor
that matches super
25.04.17 Igor Khokhriakov 34
Refactoring
● Extract method: highlight and ctrl+alt+m
● Extract variable: highlight and ctrl+alt+v
● Extract …: Refactoring → Extract
– Constant
– Parameter
– Define
– Typedef
– Superclass
– Subclass
25.04.17 Igor Khokhriakov 35
Git integration
● Compare with branch...
● Make pull request
● Resolve conflicts
● Rebase
● Etc: VCS → Git; context menu → Git
● Local changes&history:
25.04.17 Igor Khokhriakov 36
Debugging
25.04.17 Igor Khokhriakov 37
Live template creation
25.04.17 Igor Khokhriakov 38
https://www.jetbrains.com/help/clion/2017.1/reference.html
Live coding!Live coding!
Questions?Questions?
Thank you!!!Thank you!!!

Más contenido relacionado

La actualidad más candente

The Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHubThe Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHubBigBlueHat
 
(Open Hack Night 2014) GitHub Tutorial
(Open Hack Night 2014) GitHub Tutorial(Open Hack Night 2014) GitHub Tutorial
(Open Hack Night 2014) GitHub TutorialJames Griffin
 
COSCUP Scouter: Face recognizer retrieves your Github contribution
COSCUP Scouter: Face recognizer retrieves your Github contributionCOSCUP Scouter: Face recognizer retrieves your Github contribution
COSCUP Scouter: Face recognizer retrieves your Github contributionChe-Chia Chang
 
Contributing to open source using Git
Contributing to open source using GitContributing to open source using Git
Contributing to open source using GitYan Vugenfirer
 
Introduction to git and github
Introduction to git and githubIntroduction to git and github
Introduction to git and githubAderemi Dadepo
 
Getting started With GIT
Getting started With GITGetting started With GIT
Getting started With GITGhadiAlGhosh
 
Introduction to Git and GitHub Part 1
Introduction to Git and GitHub Part 1Introduction to Git and GitHub Part 1
Introduction to Git and GitHub Part 1Omar Fathy
 
Development with Git and Gerrit - Eclipse DemoCamp Stuttgart - 2010-11-23
Development with Git and Gerrit - Eclipse DemoCamp Stuttgart - 2010-11-23Development with Git and Gerrit - Eclipse DemoCamp Stuttgart - 2010-11-23
Development with Git and Gerrit - Eclipse DemoCamp Stuttgart - 2010-11-23msohn
 
Open Innovation Lab (OIL) - 20150227 - GIT Intro Workshop
Open Innovation Lab (OIL) - 20150227 - GIT Intro WorkshopOpen Innovation Lab (OIL) - 20150227 - GIT Intro Workshop
Open Innovation Lab (OIL) - 20150227 - GIT Intro WorkshopWong Hoi Sing Edison
 
Gitlab Commit: How Containerized GitLab CI Pipelines Can Help You Streamline ...
Gitlab Commit: How Containerized GitLab CI Pipelines Can Help You Streamline ...Gitlab Commit: How Containerized GitLab CI Pipelines Can Help You Streamline ...
Gitlab Commit: How Containerized GitLab CI Pipelines Can Help You Streamline ...Nico Meisenzahl
 

La actualidad más candente (20)

The Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHubThe Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHub
 
Git kelvin
Git   kelvinGit   kelvin
Git kelvin
 
Git basics
Git basicsGit basics
Git basics
 
Git hub visualstudiocode
Git hub visualstudiocodeGit hub visualstudiocode
Git hub visualstudiocode
 
(Open Hack Night 2014) GitHub Tutorial
(Open Hack Night 2014) GitHub Tutorial(Open Hack Night 2014) GitHub Tutorial
(Open Hack Night 2014) GitHub Tutorial
 
Introduction to Git
Introduction to GitIntroduction to Git
Introduction to Git
 
Git hub
Git hubGit hub
Git hub
 
COSCUP Scouter: Face recognizer retrieves your Github contribution
COSCUP Scouter: Face recognizer retrieves your Github contributionCOSCUP Scouter: Face recognizer retrieves your Github contribution
COSCUP Scouter: Face recognizer retrieves your Github contribution
 
Contributing to open source using Git
Contributing to open source using GitContributing to open source using Git
Contributing to open source using Git
 
Introduction to git and github
Introduction to git and githubIntroduction to git and github
Introduction to git and github
 
Git & git hub
Git & git hubGit & git hub
Git & git hub
 
Getting started With GIT
Getting started With GITGetting started With GIT
Getting started With GIT
 
Introduction to Git and GitHub Part 1
Introduction to Git and GitHub Part 1Introduction to Git and GitHub Part 1
Introduction to Git and GitHub Part 1
 
Git'in on Windows
Git'in on WindowsGit'in on Windows
Git'in on Windows
 
Development with Git and Gerrit - Eclipse DemoCamp Stuttgart - 2010-11-23
Development with Git and Gerrit - Eclipse DemoCamp Stuttgart - 2010-11-23Development with Git and Gerrit - Eclipse DemoCamp Stuttgart - 2010-11-23
Development with Git and Gerrit - Eclipse DemoCamp Stuttgart - 2010-11-23
 
Git'in in 15
Git'in in 15Git'in in 15
Git'in in 15
 
Do You Get Git?
Do You Get Git? Do You Get Git?
Do You Get Git?
 
Presentation1
Presentation1Presentation1
Presentation1
 
Open Innovation Lab (OIL) - 20150227 - GIT Intro Workshop
Open Innovation Lab (OIL) - 20150227 - GIT Intro WorkshopOpen Innovation Lab (OIL) - 20150227 - GIT Intro Workshop
Open Innovation Lab (OIL) - 20150227 - GIT Intro Workshop
 
Gitlab Commit: How Containerized GitLab CI Pipelines Can Help You Streamline ...
Gitlab Commit: How Containerized GitLab CI Pipelines Can Help You Streamline ...Gitlab Commit: How Containerized GitLab CI Pipelines Can Help You Streamline ...
Gitlab Commit: How Containerized GitLab CI Pipelines Can Help You Streamline ...
 

Similar a GitHub/git+Cmake+Clion

Spring Projects Infrastructure
Spring Projects InfrastructureSpring Projects Infrastructure
Spring Projects InfrastructureRoy Clarkson
 
Spring Projects Infrastructure
Spring Projects InfrastructureSpring Projects Infrastructure
Spring Projects InfrastructureGunnar Hillert
 
GDSC PCE Hacktoberfest 1.pptx
GDSC PCE Hacktoberfest 1.pptxGDSC PCE Hacktoberfest 1.pptx
GDSC PCE Hacktoberfest 1.pptxAnandMenon54
 
Hacktoberfest GDSC Pillai College of Engineering
Hacktoberfest GDSC Pillai College of EngineeringHacktoberfest GDSC Pillai College of Engineering
Hacktoberfest GDSC Pillai College of EngineeringAnandMenon54
 
Gerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub pluginGerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub pluginLuca Milanesio
 
Git & GitHub
Git & GitHubGit & GitHub
Git & GitHubCuong Ngo
 
Digital Fabrication Studio v.0.2: Version Control System: Files
Digital Fabrication Studio v.0.2: Version Control System: FilesDigital Fabrication Studio v.0.2: Version Control System: Files
Digital Fabrication Studio v.0.2: Version Control System: FilesMassimo Menichinelli
 
How I become Go GDE
How I become Go GDEHow I become Go GDE
How I become Go GDEEvan Lin
 
Git for folk who like GUIs
Git for folk who like GUIsGit for folk who like GUIs
Git for folk who like GUIsTim Osborn
 
Sourcing by Source Code: Find the Code and You Find the Developer
Sourcing by Source Code: Find the Code and You Find the DeveloperSourcing by Source Code: Find the Code and You Find the Developer
Sourcing by Source Code: Find the Code and You Find the DeveloperRecruitingDaily.com LLC
 
Git in the European Parliament
Git in the European ParliamentGit in the European Parliament
Git in the European ParliamentJean-Pol Landrain
 
Introduction to git, an efficient distributed version control system
Introduction to git, an efficient distributed version control systemIntroduction to git, an efficient distributed version control system
Introduction to git, an efficient distributed version control systemAlbanLevy
 

Similar a GitHub/git+Cmake+Clion (20)

Git_Git_Lab_1664715263.pdf
Git_Git_Lab_1664715263.pdfGit_Git_Lab_1664715263.pdf
Git_Git_Lab_1664715263.pdf
 
14 oct Git & GitHub.pptx
14 oct Git & GitHub.pptx14 oct Git & GitHub.pptx
14 oct Git & GitHub.pptx
 
Spring Projects Infrastructure
Spring Projects InfrastructureSpring Projects Infrastructure
Spring Projects Infrastructure
 
Spring Projects Infrastructure
Spring Projects InfrastructureSpring Projects Infrastructure
Spring Projects Infrastructure
 
GDSC PCE Hacktoberfest 1.pptx
GDSC PCE Hacktoberfest 1.pptxGDSC PCE Hacktoberfest 1.pptx
GDSC PCE Hacktoberfest 1.pptx
 
Hacktoberfest GDSC Pillai College of Engineering
Hacktoberfest GDSC Pillai College of EngineeringHacktoberfest GDSC Pillai College of Engineering
Hacktoberfest GDSC Pillai College of Engineering
 
Gerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub pluginGerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub plugin
 
Advance workshop on git
Advance workshop on gitAdvance workshop on git
Advance workshop on git
 
Git & GitHub
Git & GitHubGit & GitHub
Git & GitHub
 
Copy of GDSC Hacktober.pptx
Copy of GDSC Hacktober.pptxCopy of GDSC Hacktober.pptx
Copy of GDSC Hacktober.pptx
 
Mini git tutorial
Mini git tutorialMini git tutorial
Mini git tutorial
 
Digital Fabrication Studio v.0.2: Version Control System: Files
Digital Fabrication Studio v.0.2: Version Control System: FilesDigital Fabrication Studio v.0.2: Version Control System: Files
Digital Fabrication Studio v.0.2: Version Control System: Files
 
How I become Go GDE
How I become Go GDEHow I become Go GDE
How I become Go GDE
 
database.pptx
database.pptxdatabase.pptx
database.pptx
 
Git for folk who like GUIs
Git for folk who like GUIsGit for folk who like GUIs
Git for folk who like GUIs
 
GIT-FirstPart.ppt
GIT-FirstPart.pptGIT-FirstPart.ppt
GIT-FirstPart.ppt
 
Sourcing by Source Code: Find the Code and You Find the Developer
Sourcing by Source Code: Find the Code and You Find the DeveloperSourcing by Source Code: Find the Code and You Find the Developer
Sourcing by Source Code: Find the Code and You Find the Developer
 
Git in the European Parliament
Git in the European ParliamentGit in the European Parliament
Git in the European Parliament
 
Git & GitHub N00bs
Git & GitHub N00bsGit & GitHub N00bs
Git & GitHub N00bs
 
Introduction to git, an efficient distributed version control system
Introduction to git, an efficient distributed version control systemIntroduction to git, an efficient distributed version control system
Introduction to git, an efficient distributed version control system
 

Más de Igor Khokhryakov

X-Environment Metadata Management
X-Environment Metadata ManagementX-Environment Metadata Management
X-Environment Metadata ManagementIgor Khokhryakov
 
Observability of the SCADA Systems Using Elastic APM, Reactive Streams and As...
Observability of the SCADA Systems Using Elastic APM, Reactive Streams and As...Observability of the SCADA Systems Using Elastic APM, Reactive Streams and As...
Observability of the SCADA Systems Using Elastic APM, Reactive Streams and As...Igor Khokhryakov
 
Waltz-Controls presentation for Canadian Light Source
Waltz-Controls presentation for Canadian Light SourceWaltz-Controls presentation for Canadian Light Source
Waltz-Controls presentation for Canadian Light SourceIgor Khokhryakov
 
Waltz presentation at ASU and ANL
Waltz presentation at ASU and ANLWaltz presentation at ASU and ANL
Waltz presentation at ASU and ANLIgor Khokhryakov
 
1st Tango Users Group Russia meeting, overview
1st Tango Users Group Russia meeting, overview1st Tango Users Group Russia meeting, overview
1st Tango Users Group Russia meeting, overviewIgor Khokhryakov
 
Applying Enterprise technologies in Science
Applying Enterprise technologies in ScienceApplying Enterprise technologies in Science
Applying Enterprise technologies in ScienceIgor Khokhryakov
 

Más de Igor Khokhryakov (7)

X-Environment Metadata Management
X-Environment Metadata ManagementX-Environment Metadata Management
X-Environment Metadata Management
 
Observability of the SCADA Systems Using Elastic APM, Reactive Streams and As...
Observability of the SCADA Systems Using Elastic APM, Reactive Streams and As...Observability of the SCADA Systems Using Elastic APM, Reactive Streams and As...
Observability of the SCADA Systems Using Elastic APM, Reactive Streams and As...
 
Waltz-Controls presentation for Canadian Light Source
Waltz-Controls presentation for Canadian Light SourceWaltz-Controls presentation for Canadian Light Source
Waltz-Controls presentation for Canadian Light Source
 
Waltz presentation at ASU and ANL
Waltz presentation at ASU and ANLWaltz presentation at ASU and ANL
Waltz presentation at ASU and ANL
 
TangoWebapp insights
TangoWebapp insightsTangoWebapp insights
TangoWebapp insights
 
1st Tango Users Group Russia meeting, overview
1st Tango Users Group Russia meeting, overview1st Tango Users Group Russia meeting, overview
1st Tango Users Group Russia meeting, overview
 
Applying Enterprise technologies in Science
Applying Enterprise technologies in ScienceApplying Enterprise technologies in Science
Applying Enterprise technologies in Science
 

Último

GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfFerryKemperman
 
Precise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalPrecise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalLionel Briand
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Mater
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmSujith Sukumaran
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Velvetech LLC
 
Salesforce Implementation Services PPT By ABSYZ
Salesforce Implementation Services PPT By ABSYZSalesforce Implementation Services PPT By ABSYZ
Salesforce Implementation Services PPT By ABSYZABSYZ Inc
 
SensoDat: Simulation-based Sensor Dataset of Self-driving Cars
SensoDat: Simulation-based Sensor Dataset of Self-driving CarsSensoDat: Simulation-based Sensor Dataset of Self-driving Cars
SensoDat: Simulation-based Sensor Dataset of Self-driving CarsChristian Birchler
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Cizo Technology Services
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanyChristoph Pohl
 
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...confluent
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Andreas Granig
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureDinusha Kumarasiri
 
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...OnePlan Solutions
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based projectAnoyGreter
 
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...OnePlan Solutions
 
PREDICTING RIVER WATER QUALITY ppt presentation
PREDICTING  RIVER  WATER QUALITY  ppt presentationPREDICTING  RIVER  WATER QUALITY  ppt presentation
PREDICTING RIVER WATER QUALITY ppt presentationvaddepallysandeep122
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationBradBedford3
 
VK Business Profile - provides IT solutions and Web Development
VK Business Profile - provides IT solutions and Web DevelopmentVK Business Profile - provides IT solutions and Web Development
VK Business Profile - provides IT solutions and Web Developmentvyaparkranti
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesŁukasz Chruściel
 

Último (20)

GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdf
 
Precise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalPrecise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive Goal
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalm
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...
 
Salesforce Implementation Services PPT By ABSYZ
Salesforce Implementation Services PPT By ABSYZSalesforce Implementation Services PPT By ABSYZ
Salesforce Implementation Services PPT By ABSYZ
 
SensoDat: Simulation-based Sensor Dataset of Self-driving Cars
SensoDat: Simulation-based Sensor Dataset of Self-driving CarsSensoDat: Simulation-based Sensor Dataset of Self-driving Cars
SensoDat: Simulation-based Sensor Dataset of Self-driving Cars
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
 
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with Azure
 
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based project
 
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
 
PREDICTING RIVER WATER QUALITY ppt presentation
PREDICTING  RIVER  WATER QUALITY  ppt presentationPREDICTING  RIVER  WATER QUALITY  ppt presentation
PREDICTING RIVER WATER QUALITY ppt presentation
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion Application
 
VK Business Profile - provides IT solutions and Web Development
VK Business Profile - provides IT solutions and Web DevelopmentVK Business Profile - provides IT solutions and Web Development
VK Business Profile - provides IT solutions and Web Development
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New Features
 

GitHub/git+Cmake+Clion

  • 1. GitHub/git +GitHub/git + CMake +CMake + CLionCLion
  • 3. 25.04.17 Igor Khokhriakov 3 Git “Git was created by Linus Torvalds in 2005 for development of the Linux kernel, with other kernel developers contributing to its initial development.” Wikipedia.org According to StackOverflow survey 2017 ~70% of developers are using git
  • 4. 25.04.17 Igor Khokhriakov 4 Key points about Git ● Strong support for non-linear development – a core assumption is that a change will be merged more often than it is written ● Distributed development – Git gives each developer a local copy of the full development history ● Efficient handling of large projects – an order of magnitude faster than some version control systems
  • 6. 25.04.17 Igor Khokhriakov 6 GitHub ● Hosting that provides git service ● Suddenly became a central feature in git ecosystem – My personal experience is that back in 2012 they did not have even in-line commit comment (vs bitbucket)
  • 7. 25.04.17 Igor Khokhriakov 7 Summary SourceForge/svn = GitHub/git aka Hosting/repository SourceForge/svn ≠ GitHub/git GitHub provides tons of features and integrations: travis, appveyor, read-the- docs, ...
  • 9. 25.04.17 Igor Khokhriakov 9 Git concept ● Simple case: one user; direct access to the remote repo – Create new file:
  • 10. 25.04.17 Igor Khokhriakov 10 Git concept – Working with branches: ● $> git branch my_branch ● $> git checkout my_branch – Shortcut: git checkout -b my_branch ● Do stuff ● $> git push -u my_branch origin – Merging branch into the master ● $> git checkout master ● $> git merge my_branch
  • 11. 25.04.17 Igor Khokhriakov 11 Git cheat sheet http://files.zeroturnaround.com/pdf/zt_git_cheat_sheet.pdf
  • 13. 25.04.17 Igor Khokhriakov 13 GitHub concept ● Contributing via Pull-Request (PR)
  • 14. 25.04.17 Igor Khokhriakov 14 GitHub concept – Creating a Pull-Request ● GitHub fork ● $> git clone … ● $> git checkout -b feature ● Do stuff ● $> git push ● GitHub create a Pull-Request ● Do more pushes
  • 15. 25.04.17 Igor Khokhriakov 15 GitHub concept – Rebasing onto master ● $> git pull –rebase upstream master ● $> git push – Closing the PR ● maintainer(s) approval(s) + tests passed ● GitHub megre PR ● $> git branch -d feature ● Sync fork master (origin) with upstream master – $> git checkout master; git pull upstream master
  • 17. 25.04.17 Igor Khokhriakov 17 https://www.atlassian.com/git/tutorials
  • 18. 25.04.17 Igor Khokhriakov 18 Keep in mind ● Git is very powerful and flexible – github.com/tango-controls/cppTango ● Merged 4 repositories ● Preserved commits history ● Preserved branches Do not hesitate to google the most astounding ideas aka How can I do X in git
  • 20. 25.04.17 Igor Khokhriakov 20 CMake ● Cross-platform build automatization tool ● Declarative scripting language for managing native projects ● Dependency management (via pkg-config or cmake modules) ● Testing ● Packaging
  • 21. 25.04.17 Igor Khokhriakov 21 CmakeLists.txt
  • 22. 25.04.17 Igor Khokhriakov 22 Build using cmake ● $> mkdir build ● $> cd build ● $> cmake .. ● $> make ● $> make install … better use IDE like CLion
  • 23. 25.04.17 Igor Khokhriakov 23 CMake guide lines ● Use the following directory structure: – configure – include – docs – src – test ● Use dedicated project when configuration is totally different from the root project
  • 24. 25.04.17 Igor Khokhriakov 24 CMake guide lines ● Split complex project into modules – add_library(my_module OBJECT …) ● Use CTest for integration testing. Unit tests must be independent ● Use CPack to generate packages and custom targets to deploy them – add_custom_target(COMMAND curl ...)
  • 25. 25.04.17 Igor Khokhriakov 25 Where get help? ● No good book :( ● Find some open-source project and explore it – https://github.com/pni-libraries/libpnicore – https://github.com/ufo-kit/ufo-core ● CMake itself... for gurus
  • 28. 25.04.17 Igor Khokhriakov 28 Agenda ● CMake support ● Navigation ● Refactoring ● Git integration ● Debugging ● Creating live templates
  • 29. 25.04.17 Igor Khokhriakov 29 CMake support File → settings OR ctrl+alt+s
  • 30. 25.04.17 Igor Khokhriakov 30 CMake support ● Run targets
  • 31. 25.04.17 Igor Khokhriakov 31 Navigation ● Find class: ctrl+n ● Find file: ctrl+shift+n ● Subclasses: ● Implementation &Override:
  • 32. 25.04.17 Igor Khokhriakov 32 Navigation ● Method lookup: ctrl+F12 OR structure tab ● Code navigation: ctrl+click on an item ● Find usages: Alt+F7
  • 33. 25.04.17 Igor Khokhriakov 33 Refactoring ● Rename: shift+F6 ● Change signature: ctrl+F6 ● Move entity: F6 ● Generate definitions: ctrl+shift+d ● Generate … : alt+insert ● Generate constructor that matches super
  • 34. 25.04.17 Igor Khokhriakov 34 Refactoring ● Extract method: highlight and ctrl+alt+m ● Extract variable: highlight and ctrl+alt+v ● Extract …: Refactoring → Extract – Constant – Parameter – Define – Typedef – Superclass – Subclass
  • 35. 25.04.17 Igor Khokhriakov 35 Git integration ● Compare with branch... ● Make pull request ● Resolve conflicts ● Rebase ● Etc: VCS → Git; context menu → Git ● Local changes&history:
  • 37. 25.04.17 Igor Khokhriakov 37 Live template creation
  • 38. 25.04.17 Igor Khokhriakov 38 https://www.jetbrains.com/help/clion/2017.1/reference.html

Notas del editor

  1. $> git init $> git pull === $> git fetch & git merge $> git remote -v
  2. Switch to browser
  3. cppTango test/test_suite is a dedicated project
  4. Live template variables: https://www.jetbrains.com/help/clion/2017.1/creating-and-editing-template-variables.html