Posted: . At: 6:55 PM. This was 6 years ago. Post ID: 12469
Page permalink. WordPress uses cookies, or tiny pieces of information stored on your computer, to verify who you are. There are cookies for logged in users and for commenters.
These cookies expire two weeks after they are set.


Updating an open-source project is fun.


I have updated my System Information project, I used git to push changes to the repo from my local machine. This is not too hard.

Add files to the main branch like this.

jason@Yog-Sothoth:~/Documents/sysinfo$ git add src/iface.h

Then push the changes to the repo.

jason@Yog-Sothoth:~/Documents/sysinfo$ git push
Username for 'https://github.com': john302
Password for 'https://[email protected]': 
Everything up-to-date

Then finishing the process.

jason@Yog-Sothoth:~/Documents/sysinfo$ git commit --all
[master da855df] Adding proper files.
 2 files changed, 462 insertions(+)
 create mode 100644 src/iface.h
 create mode 100644 system-info
jason@Yog-Sothoth:~/Documents/sysinfo$ git push
Username for 'https://github.com': john302
Password for 'https://[email protected]': 
Counting objects: 5, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (5/5), done.
Writing objects: 100% (5/5), 4.61 KiB | 4.61 MiB/s, done.
Total 5 (delta 1), reused 0 (delta 0)
remote: Resolving deltas: 100% (1/1), completed with 1 local object.
To https://github.com/john302/sysinfo.git
   2c77eee..da855df  master -> master

Then the whole thing is up to date. I added proper code for returning the screen resolution and querying for the IP addresses of the network interfaces in a Linux system. This code may not be portable, as it requires Xorg, but it does work.

Install my little program like this.

git clone https://github.com/john302/sysinfo.git

But this is not a hard process, I only had to setup my username and e-mail address to configure git, and now I can push updates easily. Without needing a web browser.

This is how to list files in the main branch.

jason@Yog-Sothoth:~/Documents/sysinfo$ git ls-tree -r master --name-only
LICENSE
README.md
makefile
src/iface.h
src/strings.h
src/sysinfo.cpp
src/sysinfo.h
system-info

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.