Skip to content

Commit

Permalink
Add C++ HelloWorld example and corresponding CI job
Browse files Browse the repository at this point in the history
  • Loading branch information
Tobias Frust committed Jul 9, 2019
1 parent f779c61 commit 0a6e335
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 2 deletions.
18 changes: 16 additions & 2 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
hello-world:
build:gcclatest:
image: gcc:latest
stage: build
script:
- echo "Hello World"
- g++ src/helloworld.cpp -o helloWorld
artifacts:
paths:
- helloWorld

test:gcclatest:
image: gcc:latest
script:
- ls
- chmod +x helloWorld
- ./helloWorld
dependencies:
- build:gcclatest
6 changes: 6 additions & 0 deletions src/helloworld.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#include <iostream>

int main(){
std::cout << "Hello World!" << std::endl;
return 0;
}

0 comments on commit 0a6e335

Please sign in to comment.