CppCast - Travis CI
Episode Date: June 1, 2017Rob and Jason are joined by Richel Bilderbeek to talk about the benefits of using Travis CI for C++ developers and the role of C++ in theoretical biology. Richel Bilderbeek is a C++ developer ...for 17 years. He is mostly interested in what the literature has to say about good C++ practices, then teaching children and to adults, additionally writing articles, blog posts and tutorials. In his professional life, he is a PhD in theoretical biology. News Writing a Really, Really Fast JSON Parser C++ Online Compilers Looking for Proofreaders for my new Book: Concurrency with Modern C++ Richel Bilderbeek @rjcbilderbeek Richel Bilderbeek's GitHub Richel Bilderbeek's homepage Links Travis CI Travis CI Tutorial Science and Hi-Tech Day (Dutch) Sponsors Conan.io Hosts @robwirving @lefticus Better C++/Chicago
Transcript
Discussion (0)
This episode of CppCast is sponsored by JFrog, the universal artifact repository, including C++ binaries thanks to the integration of Conan, C, and C++ Package Manager.
Start today at jfrog.com and conan.io.
CppCast is also sponsored by CppCon, the annual week-long face-to-face gathering for the entire C++ community.
Get your ticket now or submit a talk. The deadline to get in a submission is June 11th.
Episode 103 of CppCast with guest Richelle Bilderbeek,
recorded May 30th, 2017.
In this episode, we talk about fast JSON parsing and online compilers.
Then we talk to Rochelle Bilderbeek about Travis CI.
Rochelle tells us about how C++ developers can take advantage of Travis,
and we talk about his teaching efforts. Welcome to episode 103 of CppCast, the only podcast for C++ developers by C++ developers.
I'm your host, Rob Irving, joined by my co-host, Jason Turner.
Jason, how are you doing today?
Pretty good, Rob. How are you doing?
Doing good. You start your CppCon submissions yet?
Yes, I've done one submission to CppCon. I will be doing a second.
And I have done two and maybe three to Meeting C++, actually.
Oh, okay.
And when's the deadline for Meeting C++?
Tomorrow.
Tomorrow, okay.
So by the time you're listening to this, the deadline has passed.
CppCon submission, I believe, is July 11th?
Yes.
Okay, so you still have some time for that one.
At the top of every episode, I'd like to read a piece of
feedback. This week we got a message from
Patrick on Facebook
and he wrote in, hey guys, any thoughts on
publishing on the Spotify platform?
We went ahead and
submitted CppCast to be on
Spotify. I'm not sure if they accept
all podcasts. It looks like it's kind of a
beta program right now, but hopefully we will get in there and you'll be able to find CppCast on Spotify,
which should bring in some new listeners, which would be great. We'd love to hear your thoughts
about the show as well. You can always reach out to us on Facebook, Twitter, or email us
at feedback at cppcast.com. And don't forget to leave us a review on iTunes. Joining us today is Richelle Bilderbeek.
Richelle is a C++ developer for 17 years.
He's mostly interested in what the literature has to say about good C++ practices, then
teachings to children and to adults.
Additionally, writing articles, blog posts, and tutorials.
In his professional life, he has a PhD in theoretical biology.
Richelle, welcome to the show.
Thanks, Rob.
Thanks for having me. What is theoretical biology. Richel, welcome to the show. Thanks, Rob. Thanks for having me.
What is theoretical biology?
Yeah, so you know biology,
but then it's about the mathematics
and computer simulations,
investigating the laws of nature.
Ooh, nicely phrased, isn't it?
So have you, I mean, do you do research in theoretical biology?
Is that what you've ended up doing with your career at all?
Yeah, in theoretical biology, yes, we do research, but it's a very broad field.
There can be practical questions, like, for example, human species.
We have two sexes, males and females.
Bacteria only have one.
Why is that? Why don't we have only one? Because there are benefits in having one sex. But it can also be, for example,
I work on speciation models. So if we have two DNA sequences of two different species,
some people like to calculate when they have their common ancestor. And that's what theoreticians do,
for example, among many other things.
That's very interesting.
Now, I'm curious, so what's the most interesting thing that you have worked on personally
in theoretical biology?
Well, as biologists, we have these cool stories about reproduction. So my most fun to talk about project is about earthworms.
So I've worked on earthworms.
It was my first project.
And earthworms are hermaphroditic.
That means they're male and female at the same time.
They cannot mate with themselves, but they can mate with another earthworm.
And this is a very gruesome process
when they do they intertwine and they stick 60 ct 60 pins of let's transform it to human
proportions of one decimeter inside each other and inject each other with acidic sperm in which
sometimes they can dissolve in each other's sperm this is very um how do you
call it hefty very very strong um harm they do to each other and i have been simulating these
creatures in my computer and it's also fun that you have on your laptop and the memory that these
that you have species evolving mutatingating, and see what's happening.
That's just fun.
And actually the question was, so there was this Flemish professor,
and he claimed that hermaphrodites, so we are a common course.
We have males and females, but you are either a male or either a female.
And the hermaphrodites, they are both at the same time.
And there was this Flemish professor that said that hermaphrodites, on average, have
a lower fitness, as in success in raising offspring, than conochorists.
And he said, thus, rainworms will evolve into conochorhists.
And that's a bit of – that's an argument you cannot make because the individual will always improve its own fitness over the cost of a species.
It's very selfish. So, for example, earthworms, they harm each other as a species, but having this harmful acidic sperm benefits the individual.
So, my simulation, but it was just a very simple simulation. I was just a student at the time.
I've seen it.
They always, hermaphroditism was evolved and harmful sperm was always evolved because individuals gained for it
gained fitness for themselves with it for example if let's make a mathematical thing so let's say
there are two people uh two rainworms of course um mating with a receptive rainworm earthworm
and let's say that they are nice both of them then and let's say that the receptive
let's call her the female just that um that she can have produced 10 eggs and if both of the
rainworms like call them the males for for this story now if both of them are friendly then five
eggs will be fertilized by the first and five by the second rainworm on average. But if you have this acidic sperm, that means, let's say, one of the two will develop this,
then you could say that she can only produce eight eggs because she's damaged,
but six of them will be fertilized by the less friendly rainworm.
So this has an advantage for the individual itself, but harms the species as a whole.
That's an example. I hope it's not too long of an example.
No, it's interesting.
Yeah, very interesting.
Okay, well, Richelle, we have a couple
articles to talk about. Feel free to
comment on any of these and then we'll start talking
maybe more about
your biology work and how it
relates to C++ programming
and also your interest in Travis.
Great.
Okay.
So this first article is from Chad Austin's blog,
and it's about writing a really, really fast JSON parser.
And I thought this was pretty interesting.
He talks about how this other author who wrote a different JSON parser
was able to get significantly improved performance
with loop unrolling. Jason, what were you thinking about this one? I definitely tend towards the
write clean code and let the compiler do its job. And so I'm surprised to see how much of a gain
there could be with some loop unrolling and some of these other tricks that he did
that helped optimize the pipeline and the compiler,
things that the compiler wasn't necessarily able to do on its own.
Yeah, and one thing he made note of towards the end
is he compared the performance on different compilers,
and I think GCC did a better job
and didn't gain as much benefit from the loop unrolling, if I have that correct?
That is what I read also.
Yeah.
Rochelle, do you have any thoughts on this article?
Yes.
What I liked is, so I'm on Jason's side here as well, that you shouldn't help your compiler too much, like STL also spoke about that.
So I especially liked the phrase, you should not help your compiler, but it appreciates
any help it can get. And I found that such a very nice sentence. But yeah, I prefer writing
clean code myself first. And if you measure it faster, then it's just great, I think.
One of the things that he pointed out was uh it looks like visual studios optimizer just
isn't quite as up to par as clang and gccs and it benefited more from some of these manual
tunings right but it's still a very good story i think that our listeners should read it and see
where he abled to identify the points where he could speed up his own code.
I mean, some of them, like he changed his enum to being a UNT8T instead of the default 32-bit integer or 64-bit integer or whatever the default was.
And got significant gains there also. Yeah, it's definitely a good article, and he really breaks down where he was able to make these performance gains, which was nice to read.
And he kind of brought out some assembly code, too, showing what the code was doing exactly.
Right.
Okay, next one is on Arn Mertz's blog, Simplify C++.
And this was a list and feature comparison
of different online C++ compilers
that I thought was pretty valuable.
The first three he mentions,
we've talked about on the show before,
Wandbox, Compiler Explorer, and Colaroo.
But then he went into a whole bunch of other ones
that I don't think I've really heard of before.
So that was interesting to see that there were so many available, although he
really kind of points to those first three and saying you can really get by
using those three. They're kind of the best available.
It's quite the extensive list. Yeah, it definitely is.
One thing I thought was interesting is,
and Jason, maybe you've heard this before, when talking about Compiler Explorer, which is run by Matt Godbolt, he said people will sometimes say they're Godbolting some code.
You've heard that Matt Godbolt's last name being used as a verb before?
Yes.
I actually, well, I sent Matt a message after I had seen one that was similar.
It was something like, I'm going to Godbolt some code on Godbolt.
It was basically noun and verb in the same sentence.
You must be proud.
Yeah, well, actually, Jason, so I've seen some of your presentations.
And now, only now, I understand that you've set up this environment yourself i thought
you you were gold bolting there well yeah yeah not quite i mean yes it's it is relatively easy
to set up the compiler explorer on your own system and i guess for the listeners who don't know that
i mean it's it's a clone and you run a couple of commands.
You just have to install Node.js and whatever compilers you want
and set up a couple of configuration things.
But its defaults are really pretty good,
and it's pretty easy to set up if you have a reason to run one locally.
And I've even talked to some people who run their own Compiler Explorer
inside their own company so that they can do what they want to do on the compilers
that they're testing for their own specific usage,
but just have it on their local internet.
Because they're afraid of letting their code be on a public...
They might be working on sensitive code,
or they might be working on a particular compiler
they want to test, or whatever, yeah.
Okay.
Anything else you guys wanted to call out in this
one no okay and then the last article is uh from rainier grim's blog and he is looking for proof
readers for his new concurrency with modern c++ book um and i believe this book is coming out
simultaneously in both german and english So I think he's mostly looking
for English proofreaders just to make sure that the translation came across properly.
Right. So there are a couple of interesting notes in here. He says he does want you to be
a native English speaker if you're going to proofread it. And this is uh interesting um you get one percent of the royalties if you do proofread the entire
book you have to proofread the entire book not just a chapter yeah so if you proofread the entire
book um you could make a decent amount of money from helping him out it's an interesting experience
i worked with him uh helped him proofread his previous book, the C++ Standard Library,
but I only did one chapter of that.
It was definitely a fun and interesting experience.
Yeah.
Well, I'm happy to hear.
I thought this 1%
of the profit,
I thought that was standard, but thanks to
you now telling me that it's an experiment,
thanks for clearing that up.
I have no idea.
I've never heard of someone
offering to pay that much to proofreaders before,
but I maybe
haven't paid attention to it too much. I don't know.
Also, personally, I was a bit
disappointed because I would love to proofread
this work, but I'm not a native
English speaker, nor a native
German speaker.
So I wish I could take some look at the code, but too bad.
Well, I'm sure the book will be available once he's done getting the proofreading, right?
Yeah.
Yeah.
Okay, so, Richel, the main thing we want to talk to you about today is Travis.
I think a lot of our listeners have probably heard of Travis CI, but for those that
aren't familiar with it, or maybe they've only seen the little badge on a GitHub repo,
do you want to tell us about Travis and what it's capable of? Oh yeah, sure. So Travis,
it's a continuous integration service. So hence it's called Travis CI, Continuous Integration. And what it does, if you push your code to GitHub or Bitbucket or whatever, it can do something then.
It can respond to this.
It can start a script and run whatever you want it to do.
And then, for example, you let it see if it can actually build your code still, run your test suites, and many, many things more.
So you said it can do whatever you want it to do.
I guess let's maybe go through some examples of what it can do.
I mean, compiling and running the test suite is obvious,
but there are other things that you'd use Travis for?
Oh, definitely.
I actually like to collect all the tests I do on my code.
For example, I like to do a CPP check on it.
So there was this guest of yours, Daniel.
So I like to CPP check everything I check in.
Also OC Lint.
It's some kind of Lint.
It's a bit like a Metrix++.
You've also spoken about that.
Oh, it's in your CPP best practices thing yes i like to do
gprof for profiling so i always want to have it run a bit a build that only does some profiling
information and the thing i'm most interested in i like to do data race detection memory
leak detection using valgrind i even do spell checking on things that
for example on the readme if there's there are spell checks in it. Proslint is a
tool that can detect stylistic errors so so if you use the word very for example
the word very is not very informative so you should remove it. So I like to put everything there.
I think it could be interesting to actually,
I mean, maybe we're getting ahead of ourselves a little bit here,
but I think it could be interesting to go over each one of these things and talk about how Travis can help running those tools
and what the results are.
So you compile and run your test.
Then what happens?
Well, when I run my test, I put all these flags in it.
So when it's run, it says that all tests are passed,
that everything worked, hopefully.
But also I do this.
So I also check with Valgrind if there have been memory leaks.
I just like to monitor those things.
So if Valgrind detects a memory leak, then how do you report that to the developer?
Great question.
So you always see these Travis batch status on the GitHub.
So if you click on them, you can see the Travis build log.
And in that build log, you can see the output of Valgrind, Hellgrind, whatever you've put
there. So you can just read it. And for example, with Valgrind, I usually like to put it in
early because there were always some false positives in there. And then when I do something weird, I want to see if it changes.
So for a value grinder, I usually use that as a delta.
When I put in something fishy, I want to see if something changed.
So can Travis report on this delta automatically or is this something that you're looking for
manually as the human involved in the process?
Oh, yes.
I do this manually because I'm not always interested in that output. So it's there. that you're looking for manually is the human involved in the process oh yes i look as a i do
this manually because i'm not always interested in that output so it's there i can always look back
if i just expect something to happen but it's it's there okay when i'm i'm sorry go ahead yeah
so i only look back when i when i need it for, also what I do, I like to also do a release build.
And then I start my executable with some flag, usually profiling or profile or whatever.
And then it does some important things.
For example, in a game, I want to see the main game on screen or the main game loop.
And then I let it run for, let's say, 10 minutes or five minutes.
You can do that on Travis. You can see see what's going on but it can run there and then i'm going to see the gprof log and
it shows you the profiling log and sometimes you see that yeah yeah when there's a big change in
what's happened that's uh interesting and also you can clearly see when you have fixed this speed
bottleneck that makes you aware where so for example if you have fixed this speed bottleneck. That makes you aware where,
so for example, if you have four sprites on your screen,
and let's say you profile with a thousand screens,
so a thousand frames,
you expect 4,000 times a call to this draw sprite function
or whatever function it is.
And if it's 10 times more,
then something fishy is going on.
So it makes you more aware of what's going on in the back with your code.
That's interesting.
I did not know that Travis would let you run any program that showed a UI.
Yes, but of course you cannot click on your mouse button.
But it starts a virtual server.
And actually it's already – but now we're getting really ahead.
The main thing I miss in Travis is that I can also do GUI testing.
So what I love to do on my local computer is that I can start a script,
that my program starts and I see the mouse click on the things,
that you have this outside test, like a user would click there and then there and then there,
and then something should happen.
You cannot do that on Travis as far as I know.
And I've been looking for this solution already a year,
and I've joined LDTP, Linux Desktop Project, and many other things like Sikuli or
I cannot get something to work
that I can both see locally
and run on Travis and
works on both
spots. So I've abandoned
that approach but
just doing basic things like for example
I used a Qt framework
using Qtest
with Qtest.
With Qtest, you can send mouse clicks and key presses from the inside from your test suite.
That works flawlessly on Travis.
But these outside things that you say, I want to click at that position on screen, which is absent, but it can emulate that somehow.
I think I should, I should,
I hope. You can't do that there.
So to pull back a little bit,
why do you think C++ developers should
be using Travis? Why do you think it's so important?
Because it ensures quality.
I love
my...
You've probably also, for example, I know – so, Jason, you use Decent CI.
So, yeah, that's a question.
So, continuous integration, I love that I can see that it's good, that it does compile and also compiles tomorrow.
I like to see when it breaks.
I like to see that my tests run.
I don't like doing manual things.
Everything you like, those good practices, I love to automate it.
And we also appreciate when things are automated.
I don't know if you know people who do profiling manually.
I never did it myself until I discovered this.
Or OC Lint or CPP Check.
Yeah.
Perhaps I'm too lazy for that.
So C++ developers should use Travis because we're lazy.
Oh, yes.
Oh, yes.
It does take some time to to to set up so for me yeah if you use traffic it's a
kind of badge of quality so i will more likely use code that has a travis badge um but also
because what i like to do is um when i can it gives you a way to communicate. For example, if I have Travis on my GitHub,
sometimes you get these pull requests from friendly people
that like to contribute to your code, and that's just great.
But sometimes the code they submit, for example, introduces new bugs,
and they haven't tested it sometimes, or they introduce a different style,
things you should never do according to CPP check or memory leaks or whatever.
So before that, I had to check these things manually and had to say,
Ah, your style is off.
Please put your brackets there.
Please don't do that.
And that's not a fun thing to do.
Sure.
What now happens is that Travis checks it for me.
It gives a red flag because when the the pull request causes a failure somewhere,
it will give this red flag.
And then you can say,
please fix the problem that Travis has detected before I'll merge.
And people accept that more likely,
because it's a machine that told them to improve their code.
I think it works great with collaboration.
Is that something that Travis does automatically? As soon
as you set up your normal CI script
for your repo, as soon as the
pull request comes in, it can
trigger to run all those tests
against the pull request code?
Yes. I only know GitHub,
so I'm not sure if Bitbucket does it or the
others, but GitHub does
this great.
So from a kind of practical standpoint, you've talked about a lot of different tools.
OC, Lint, Valgrind, spell checking, CPP check.
Do you run these as separate targets in Travis,
or do you have one uber target, I guess, that builds them all?
Yeah, well, my Travis build script does all of them.
Okay.
Yeah, so that means that sometimes you need to compile your project twice,
one in debug mode, one in release mode.
Sometimes I have to switch, I have to turn things off due to this
because you only get one hour for free in open source development for free.
Okay. If you want to have longer builds you have to pay i think also that that's not a necessarily bad thing because you have to think more instead of just throwing everything at it you have to
constrain yourself to this one hour of time and you have to think what is really important or
what's important now so that's's just fine, I think.
Can we talk a little bit about what the scripting language is and how you're writing Travis scripts?
What do those look like?
Oh, yeah.
So Travis uses a file called.travis.yaml.
Yeah, I never heard about YML.
The extension means YAML, yet another markup language.
It looks a bit like a list in Markdown.
So you have different sections in your code,
like install, before install, after install, script.
Script is the main thing.
And then you have to use a space and a minus and a space,
and then there your bash commands come in,
like sudo apt-get install something
or qmake or cmake or make or whatever.
And that's just a regular bash.
Yeah, so actually I use these JavaScripts
from other projects.
I just read those and copy-paste them to my command line,
and then I know that I install it on my own computer
in the correct and tested ways. Okay, sounds pretty easy to use. Yes, I think it is.
So you're saying bash scripts, does Travis only support Linux or does it
have support for Windows and other OS's? Yeah, Travis supports both Linux and macOS,
but not Windows.
They also support Android,
but I'm not aware of those
aspects of the...
I don't know much about those things.
Interesting. I wonder what the Android
support's like.
Yeah, I do too.
As far as I understood,
they use two virtualization techniques.
One of them is Docker, the other one I don't know.
So they actually set up this clean environment, set it up somehow,
then do the things you want to do on it,
and then they only keep the log and the environment they just throw away again for reuse.
Okay.
Obviously, GitHub has been becoming increasingly popular over the past few years in programming,
and I think CI is starting to get there too.
How do you think CI and Travis has changed your workflow
since you discovered it?
For me, it has changed my workflow incredibly much
because I was lazy, and I don't like to do my tests manually.
So when I can put all those good things in, I feel a better person.
Yeah, so I like to do all.
Yeah, I like to be.
Now I can actually do easily what I should always have done according to the literature.
Sure.
So that's great, I think.
And also what I like to do, for example, sometimes I like to contribute to other projects.
For example, sometimes I just can't install it, for example.
And I say, hey, is it okay if I give you traffic support?
And usually they say, oh, that's a great idea.
They say, how do you build it then exactly? And I say, yeah, this and this if I give you Travis support? And usually they say, oh, that's a great idea. They say, how do you build it then exactly?
And I say, yeah, this and this and this and this.
Oh, great.
So I put it in, in the Travis.
The project gets built, and I get to know what I want.
I want to just install the thing, the project itself, and then I can do it.
So it's also a form of documentation, a way to help other people.
Yeah. That sounds like
a really, I mean, just a great
helpful service to do
to help other projects
get CI integration
going.
I think, yes. I think
I've added Travis to approximately
40 GitHub projects now.
Wow.
Yeah, well, it's not always that much work.
Sometimes it's just copy-pasting your own script.
Sure.
So it doesn't take hours of work.
It's not that hard at all.
But this concept, like first you put in Travis,
so you say, oh, that's great.
Now we can see if our build works.
Then say, all right, is it okay if I also add CPP check?
And they say, oh, that's a great idea.
And then they found all these problems in their code.
They say, oh, we should fix it.
I say, yeah, that's a good idea.
You may want to fix that.
And then I step out of it, or perhaps I say, all right, I'll help.
But it makes also other people aware where they can improve their own code.
So I also use it for example my students
so when i have a student a minor or an adult i always give them a github that has with a
travis script that has all these tests in it before they've even perhaps even written their
first line of c++ code so then they start like adding things and see out in hello world
and then immediately they get this feedback from Travis,
like, hey, you should avoid using main should return int, for example.
Those stupid things.
It makes my students aware of those things.
It's a teaching, learning tool.
It puts you in the right style where you want to be at in the end.
It definitely sounds like a great way to be introduced into programming.
It really does.
Yeah, well, it's easy to program something,
but it's hard work to read all the literature
and see all these interviews and talks and blogs.
I like that stuff.
I just give it to them on their code.
So it's relevant and easy to read.
Oh, and it's a red flag.
So at the end of the day, the Travis build should pass.
Otherwise, they get a bad grade or whatever.
You're pretty prolific on GitHub.
You have almost 700 repositories.
And you actually went ahead and created a repository
for the show notes for this episode,
which had Travis badge for it, which is passing.
I thought that was pretty cool.
Yes, correct.
So the show notes have been checked by Aspel and Prosland.
Yes.
That's just a spell checker for the readme, I guess?
Yes.
I'm sorry, ProseLent?
Yeah, ProseLent, it checks.
There's this book, The Elements of Style.
It's about some English how-to guide that tells you about how you should write prose.
For example, you should not use clichés.
And, for example, one day I wrote a report,
and I like to say, the bird's-eye view of this is...
And you should never use a bird's-eye view,
because that's a cliché.
So I removed that, because ProseLens told me that.
Never heard of that one before.
That's pretty neat.
Yeah, no, I had no idea.
It's from Strunk and White.
Yeah, so the book's from Strunk and White,
and it's moderately influential as far as I know.
Yeah, I actually have the elements of style,
but I did not know Prose Lent existed,
so I'm totally going to look up that when we get off.
So you've added, Travis, to you said over 40 projects, I believe?
Yeah, those are external projects.
So myself, I have around 200 to 300.
That's just a wild guess.
200 to 300 projects that I've added Travis to.
So some of them are minimal
examples. I like having minimal examples.
I like that if somebody says,
I want to use Qt 5 and SFML
and I want to use Boost Test.
I say, all right, go there.
They get this one Travis script. They can just
copy-paste and work with that.
Those are about
100-200 small minimal example GitOps
that are well-connected, more or less.
But also the bigger projects,
so I know, Jason, you use Javascript.
You've checked it with a CPP check and see what happened.
So I like also to put all these tools,
see how good they are on all my code bases.
And it's a very insightful experience.
So all my games have Travis, for sure.
Most of my approximately 100 tools all have Travis.
Do you have any recommendations for our listeners for how to make Travis easier?
Like how to prepare their project for Travis integration?
Is there anything that makes it easier or harder for this?
No, I think whatever you do, you can get it to work.
Okay.
Well, I know that on Travis you can only use Clang or GCC.
So if you're on the Intel compiler, I'm not sure how that will work out.
Except for that, using Linux is very helpful because it's only Linux.
So if you would be able to compile something in the Windows
and you don't know the Linux commands to do so, that's unhelpful.
So if you use Linux,
then it's a breeze, more or less,
because you already know what to type in on your
command line. Well, then just copy
and paste it to TravisScript, and it will work.
Does it matter if
the developers using
Autocon for CMake or
Ninja or anything like that
make any difference? No, anything like that make any difference?
No, that doesn't make any difference.
Sometimes you just have to install the things.
For example, I like to use QMake and I use Qt 5.
That means that first in your script you have to install Qt 5 and then you can just use the regular QMake.
Also, for example, I like to use G++5, so I can use G++14. That means that I have to install G++5 and then redirect G++ to G++5,
and then it just works fine.
But sometimes there are these installation things that you, like,
I suggest to copy-paste from others.
Okay.
But you can find it out yourself in the end as well.
And as far as open source support on Travis,
I think you said there's a limit of running for one hour of the script.
So if your CI build takes longer than an hour,
you will be able to use the open source version.
Is that the only limit?
Like if you have multiple open source repositories under your GitHub handle,
you could have Travis running for all those as long as it's,
you know, each one is less than an hour
runtime? Yeah, well, I shared
that
fear, but
I have now a couple of
hundreds of them. Yeah, so
I suppose they don't complain.
Actually,
they are
very happy with me. I've got stickers
from them.
Yeah, so there really appears to be no limit.
Okay.
Aside from just one hour runtime.
Yes.
Wow.
Okay.
Yeah, and I think that's very impressive because I've checked out the commercial version.
So that's, I think, $60 a month.
So you could say, all right, that's I think $60 a month so you could say alright that's cheap
but for me
I wouldn't
I think that's still
I actually think it's amazingly cheap
because you have so many resources of their computers
so it's
hard to believe they really give it away
for free but they do
without any strings attached
I think it's great
I wanted to interrupt this discussion for just a moment do and without any strings attached. I think it's great.
I wanted to interrupt this discussion for just a moment to bring you a word from our sponsors.
JFrog is the leading DevOps solution provider that gives engineers the freedom of choice.
Manage and securely host your packages for any programming language with Artifactory.
With highly available registries based on-prem or in the cloud
and integrations with all major build and continuous integration tools.
Artifactory provides the only universal, automated, end-to-end solution
from development to production.
Artifactory and Bintrey now provide full support for Conan's C and C++ Package Manager,
the free open-source tool for developers that works in any OS or platform
and integrates with all build systems,
providing the best support for binary package creation
and reuse across platforms.
Validated in the field,
provide a flexible, production-ready solution,
and with a growing community,
Conan is the leading multi-platform C++ package manager.
Together, JFrog and Conan provide an effective,
modern, and powerful solution for DevOps
for the C++ ecosystem.
If you want to learn more, go to jfrog for DevOps for the C++ ecosystem.
If you want to learn more, go to jfrog.com and conan.io. Do you want to talk a little bit more about
your professional life? We talked a bit about the research
you were doing with earthworms. How exactly does C++
get applied to theoretical biology?
In theoretical biology, we make computer simulations
or mathematical approximation or just mathematical formulas,
but that's beyond C++.
But we usually have to run a lot of repetitive things
like a thousand or a million generations of populations
of a thousand to a million individuals.
So that scales up and that
that skills up and that can take can take very long it doesn't necessarily
mean that the calculations are complex but they need to be done very often and
in academia you now have multiple languages that are important one of them
is C++ basically Basically, they say that
if it needs to be fast, use C++.
But in bioinformatics,
they use Python.
And for data analysis, you use R.
So those are the three. But that's only
in the University of Groningen that I
am most aware of.
But here, mostly
they use C++. And some people
use Fortran.
But that's on older code.
And they teach, actually, there's a course called C++ for biologists that they teach here,
in which you do your first computational, you simulate your first biological things.
I have heard similar, that basically if it needs to be fast, C++, and if you need to do statistical work, then R, and Python seems to come up.
Those three languages also seem to come up in the work that I've been exposed to.
Yeah.
So I had to use R for writing simulation code,
and I have to stick to it, I think.
But I've never been so slow in developing code, I think.
So I noticed also in teaching that when I have – that a language is hard if it is hard to make it do something. And the language is easy if it's easy to make it do something. And the language is easy.
If it's easy to make it do something.
And if there's something that's done is incorrect,
that's totally unimportant.
So in R, it's very easy to make it do something.
Whereas in C++, yes, you have this type safety.
And somehow, so the compiler saves you so many bugs, and R doesn't, or does less.
And that makes C++ a hard language, but you save so much time in debugging.
So that's a student-beginner idea I see a lot nowadays.
So you said you actually teach a C++ class to all these theoretical biology students.
What's that like?
Are they receptive to learning C++ and programming in general?
Yeah, well, it's – yes.
Yeah, receptive, receptive.
What's receptive?
Yeah, well, they have to teach to learn C++ because it's the culture, it's the language used for simulation.
So you have to learn it. Yeah, it. But then there's this general thing, some people like to program
some knots, some think it's too hard, you have to persevere. I think that's rather language
independent.
But your students don't mind that it's C++, that's just what they have to do?
Yes.
In other words, okay.
But now we're talking about my adult students.
I also teach to kids.
So before this show, Jason, or Rob, I don't know whom, he sent me this question like,
how do the minor kids respond to C++? And I sent out this email to two of my students, and I got one back from a 13-year-old kid.
He said, Richelelle about c++ he said i am not
using it now but will probably be an okay language and actually what he doesn't know is how he
programmed arduino which is some kind of electronic circuit board you can program in c. And he's been using OpenGL examples in Qt Creator, which is C++.
So he doesn't feel he's using C++.
But he is.
He is.
I'll tell him tomorrow, I think.
No, you should keep it from him.
He doesn't need to know.
Yeah, it should be a secret, yes.
So you also teach Arduino classes.
And this is, you said, one of those students who's been involved in the Arduino programming?
Yes.
What is it like teaching kids C++, basically?
Do you ever get hung up on pointers or anything, or do you keep it all on a very stack-based kind
of level?
What's your approach?
That's a great question.
So when I teach C++ to my university students, then it has to be following all the guidelines.
But the Arduino, when you teach Arduino, all textbooks, they use global variables and arrays
because they don't use the STL there.
So there's a completely different approach what is wrong and right there.
So first I start with the textbook's example.
So there are a lot of examples given in the IDE, the Arduino IDE.
Yeah, you have to use globals there.
So we do.
But I will always tell them, like, one day when you grow up, you'll never use globals again so we do but i will always tell them like one day when you grow up you'll never
use globals again if everything is okay so do you also set up the arduino students with github
repositories and travis checking of some sort yes yes so most of them have a github actually
i have some students that don't have email addresses yet because they're too young to have them.
Okay.
But I do have a private mail server, so I make email addresses for them temporarily so they can verify to GitHub that they have an existing email.
And then they set up their GitHub account.
And I always follow them because they're kids.
You have to watch them.
But they do so much fun things on the Internet.
It's great to see them develop themselves.
What exactly is the age range of these kids?
And what is the program in which you're teaching them?
Is this through the university?
Oh, no.
These kids come to me in the evening, on Thursdays and Fridays evenings.
Their age, the youngest kid is seven years old wow and the oldest kid is 18 years old by definition of a kid about 17 years old then um which i so the the youngest i have two uh
kids uh volunteers of 80 years old and and they teach Scratch.
So they teach Scratch to the youngest kids.
Then we do processing,
which is some kind of Java dialect to the kids until they're 14, 15 years old.
Then we switch to C++ using SFML
and Euro3D, which is a game engine,
but then free and open source.
So that's how it more or less. So that's how they develop themselves.
Sounds interesting.
I have not tried to teach a kid to program, but it's kind of ironic, I guess, since I learned to program at a very young age. It does, I guess, you hear some of us who grew up in the 80s
kind of lament how
when the Commodore 64 days or whatever,
that you kind of had to know some programming.
You had to learn some basic
if you wanted to load your game off the floppy disk
to be able to start your game, basically.
And we've maybe kind of lost that,
but it sounds like you have found a great way
to reconnect the kids with modern
programming and microcontrollers and and all that stuff yes well also when i was a kid i also so i
was eight years old and i took my first programming course in the evenings and i was the only minor
so all the all the blokes around were 30 40 years old of course i could not estimate it well because i was just a kid but i was eight years old i took the class we had an
official exam and i passed it with flying colors actually my mom told me uh i was so i did well
there but i wished that as a kid i would have this. And all the volunteers, all the adult volunteers I have also have this idea.
Like we wish we would have had this when we were kids.
And that's why, yeah, it's great, our courses, yes.
It's so fun.
Also, the kids help teaching.
And we go to festivals.
Yeah, we go to festivals and the kids, they teach the adults, like the guests of that festival, they teach them Arduino or Processing or C++ or whatever.
That's very cool.
It's a very fun learning environment I've created there thanks to my volunteers and also the great kids because kids are important to collaborate.
How do the kids find you for this
after-school program that you're running?
I'm in some kind of
non-profit organization that's well-known
in the Netherlands and
through festivals.
So when there's some kind of maker fair,
we're there, and then we meet
our, well, sometimes new
students.
Is this with Code.org or some other nonprofit?
Oh, yes.
Yeah, not Code.org, but the Maker Faire.
I don't know if it's in America.
I'm not sure.
Yeah, so Maker Faires are also in America, yes.
Oh, yeah, because, yeah, it's international.
Yeah, so we're there.
We're at the Maker Faire. If there's some festival in my city, I ask the kids, hey, you want to join?
And they say, yes, that's fun.
Well, go ahead if you want to give
a specific plug out to your organization
or the next fair you're going to be at for the
listeners who happen to be in your area.
Well,
yeah, so the
nonprofit organization is called De Jong Onderzoekers,
De Jong Researchers,
and the next festival we'll be going
will be, oh, actually we'll be going will be
oh actually we'll have an open day
we call it the science and high tech day
it's in a couple of weeks
at the Jungwunder Zuckers in which you can
meet my kids and they will teach you
how to do a program with Arduino
or processing
but I don't know the exact date
okay well if you have a link
to that we can put it in the show notes for you.
Oh, great, I will.
Okay, and where can people find you online
or find more information about some of the stuff you're doing?
Well, my GitHub is probably the place to go.
I've pinned my favorite repositories
that I think are most important for other people to find.
Yeah, GitHub.
That's it.
Okay.
Okay.
Well, thank you so much for your time today, Rochelle.
Thank you guys so much for having me.
Yeah, thanks for joining us.
Thanks so much for listening in as we chat about C++.
I'd love to hear what you think of the podcast.
Please let me know if we're discussing the stuff you're interested in,
or if you have a suggestion.