Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Report Git Version in Csound's output #676

Closed
kunstmusik opened this issue Jul 11, 2016 · 14 comments
Closed

Report Git Version in Csound's output #676

kunstmusik opened this issue Jul 11, 2016 · 14 comments
Assignees
Milestone

Comments

@kunstmusik
Copy link
Member

Reporting the git version used to compile the application would help developers when users report problems. The information could contain the git commit hash or use git describe (for example, something like "git describe --abbrev=4 --dirty --always --tags"). We would need to figure out:

  • How to integrate getting the git version when building (likely as part of CMake?)
  • How to handle building where git is not available (i.e., user downloads tar ball)
  • Format for how to report the information

For the last point, we currently show information such as:

Csound version 6.07 (double samples) Jul 2 2016

We could have something like:

Csound version 6.07 (double samples) Jul 2 2016 [4904caa6f8ad688c59ae3703d2825162e0fa6a1a]

or using the same abbreviated commit hash as shown when using "git log --abbrev-commit", we could have something like:

Csound version 6.07 (double samples) Jul 2 2016 [commit: 4904caa]

@fsateler
Copy link
Contributor

@fsateler
Copy link
Contributor

@nwhetsell
Copy link
Contributor

For what it’s worth, I think reporting the Git commit hash with Csound’s version is a very good idea!

@kunstmusik kunstmusik added this to the 6.08 milestone Aug 24, 2016
@vlazzarini
Copy link
Member

I've done this now. Can you check whether it's the best format and we can close this ticket?

@fsateler
Copy link
Contributor

this will break ccache on every git pull. It would be great to have it defined only for musmon.c and csound.c. At the very least the definition should be restricted to the csound library...

Also, this should probably only be used when BUILD_RELEASE is not defined.

@fsateler
Copy link
Contributor

Probably minor, but this also affects builds done in a git repository not linked to this one (like the debian downstream one), and thus the hashes reported will be highly misleading

@vlazzarini
Copy link
Member

csound.c only now. I've commented out the musmon.c duplicate as it is only confusing things.
Anyway, it's there for us to decide what/how to use.

@vlazzarini vlazzarini self-assigned this Oct 21, 2016
@vlazzarini
Copy link
Member

if everyone's happy with this now, I will close the ticket.

@kunstmusik
Copy link
Member Author

I think I have it working now for Windows. CMake needed to use the windows
path for the command (i.e., c:\msys64\usr\bin\git) so I put in a
find_command to search for it.

@vlazzarini could you test to make sure this works on OSX? If so, then I'm
happy to close this.

On Fri, Oct 21, 2016 at 11:14 AM, Steven Yi stevenyi@gmail.com wrote:

The latest isn't working for me here on Windows. Investigating now, will
report back.

On Fri, Oct 21, 2016 at 5:02 AM, vlazzarini notifications@github.com
wrote:

if everyone's happy with this now, I will close the ticket.


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
#676 (comment), or mute
the thread
https://github.com/notifications/unsubscribe-auth/ABjAe2ZfsSeWTKbfmnkM6J9ViT63Z0ujks5q2H-UgaJpZM4JJjXX
.

@kunstmusik
Copy link
Member Author

I get this output with the latest from git:

$ csound --help
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
--Csound version 6.08 (double samples) Oct 20 2016
[]

At first I didn't understand what the [] was. It'd be nice if that was
removed if no git hash was found.

On Thu, Oct 20, 2016 at 5:55 PM, Felipe Sateler notifications@github.com
wrote:

this will break ccache https://ccache.samba.org/ on every git pull. It
would be great to have it defined only for musmon.c and csound.c. At the
very least the definition should be restricted to the csound library...

Also, this should probably only be used when BUILD_RELEASE is not defined.


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
#676 (comment), or mute
the thread
https://github.com/notifications/unsubscribe-auth/ABjAe8BBIp9-gCazcLwRFRv9iLB8J_ykks5q1-NTgaJpZM4JJjXX
.

@kunstmusik
Copy link
Member Author

The latest isn't working for me here on Windows. Investigating now, will
report back.

On Fri, Oct 21, 2016 at 5:02 AM, vlazzarini notifications@github.com
wrote:

if everyone's happy with this now, I will close the ticket.


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
#676 (comment), or mute
the thread
https://github.com/notifications/unsubscribe-auth/ABjAe2ZfsSeWTKbfmnkM6J9ViT63Z0ujks5q2H-UgaJpZM4JJjXX
.

@vlazzarini
Copy link
Member

Strange... the code should at least print [commit: ]

@vlazzarini
Copy link
Member

working on OSX

./csound --help
time resolution is 1000.000 ns
virtual_keyboard real time MIDI plugin for Csound
WARNING: STK opcodes not available: define environment variable RAWWAVE_PATH
(points to rawwaves directory) to use STK opcodes.
0dBFS level = 32768.0
--Csound version 6.08 beta (double samples) Oct 25 2016 
[commit: bdda230666dc8b986b7a1b9c579e0a4fd23a3b36]

@fsateler
Copy link
Contributor

FWIW, it should print [commit: none] when no hash could be found.

On 25 October 2016 at 15:23, vlazzarini notifications@github.com wrote:

working on OSX

./csound --help
time resolution is 1000.000 ns
virtual_keyboard real time MIDI plugin for Csound
WARNING: STK opcodes not available: define environment variable RAWWAVE_PATH
(points to rawwaves directory) to use STK opcodes.
0dBFS level = 32768.0
--Csound version 6.08 beta (double samples) Oct 25 2016
[commit: bdda230]


You are receiving this because you commented.
Reply to this email directly, view it on GitHub
#676 (comment), or mute
the thread
https://github.com/notifications/unsubscribe-auth/ABQsHYmFjdoEFo3cmed52qEagMa3d-yzks5q3kkvgaJpZM4JJjXX
.

Saludos,
Felipe Sateler

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants