-
Notifications
You must be signed in to change notification settings - Fork 7
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
Add sgit.1 man page, minor fixes in sgit #982
Conversation
(Well .. some warnings. See below.) Depending on system (compiler and possibly platform) different warnings were being triggered. It was easy to fix the code for some of them (like wrong prototypes and then #including stdlib.h) but this caused problems in another way (in macOS clang - clang is more strict and has -Werror or else an equivalent by default which might or might not be possible to disable .. haven't tried it) but since the code works as is I simply silenced the warnings in the Makefile. A note that might be useful to know for other Makefiles that has to do with the fact that macOS gcc equates to clang (which I have noted many times as it's an unfortunate problem): since it is seen as gcc the Makefile check for gcc only will be triggered in macOS even though the compiler is clang. A similar problem is that if one does in linux just 'make' they might end up with the compiler being 'cc' so I added an ifeq in the Makefile for just cc. It might or might not be useful to add this to the rest of the entry Makefiles. The same warnings disabled for cc and gcc were added. Another thing to keep in mind is with gcc/cc in linux it will still show the warnings that were silenced as in it will show that some warnings might have been disabled (it won't warn about the problems but will note that some warnings were disabled - no I can't figure out the real purpose of it either other than to be extra careful .. or annoying :-) ). In linux clang also triggers even more warnings including the ridiculous misleading indentation that they unfortunately adopted from gcc. These warnings were not disabled at this time. As far as the README.md goes one of the to run commands was incorrect in that when running './wall' by itself one should put in numbers only, not just any text.
Something that is lacking from the man page is that there are no examples. This is currently being justified by the fact that the README.md has examples but since that might not always be available this doesn't hold very well. This will likely be fixed another time when I have more energy, time and patience for it. As it is not clear to me how any documentation should be 'installed' I have not updated the Makefile to address this. That can be done later - or not for that matter. The usage string has been improved a bit. There was one thing that could be more clear and there was something missing too. Fixed exit codes when command line error. README.md now refers to the man page and the usage string was updated to match the usage string change. New version 0.0.11-1 28-04-2023.
Please advise on whether or not the man page should be copied to any directory. I do not mind one way or another but I felt like it should at least be here now that the repo itself has it. It doesn't have to be copied at all to any other directory but should you wish to tell me where or if you want to do it I'm happy to do it or have you take care of it. But it did feel important that it is added to the repo at least because otherwise it would not be complete. As noted in the log it does currently lack examples that the README.md has but I'll have to fix that another time ... too tired and don't have the patience for it right now. The script, also noted in the log, has had some fixes as well. As I'm very tired now I imagine I won't do more today but we'll see. Hope you're feeling better now and hope you have a great day! I'll update you more later on .. I hope. Some changes since I wrote about it earlier on. |
We recommend creating your own repo for the sgit tool. Once you do, we will clone that repo and install sgit from that repo. The Once you do, the `src/sgit' directory tree can be removed from the repo. |
But it will still be published on the website, right? Anyway it already is in a repo and I think you might have even starred it. That's what I have been doing actually: committing there and then copying the files to this repository. I can give you the link when I am at the laptop later on. This cloning idea btw is what I was referring to the other day kind of like how in mkiocccentry THAT repo clones others only that this one would clone the sgit one. You misunderstood though thinking that I was suggesting that the mkiocccentry repo should have this when I was actually thinking about simplifying the way THIS repo has it. That way I don't have to always do another pull request: you or I can j@ run a make command to do it. This way the website will have it but in an easier way. Perhaps the Makefile will be just a new rule that does the cloning and copies the files to the right directory but maybe has the files themselves (in the src directory) in the .gitignore ? Anyway that's what I meant all along: it will simplify having the script published in the website but without requiring me to repeatedly copy files over each time I make a new commit. Thank you for clarifying. I will reply to other things later .. can't sleep but still quite sleepy :( Hope you're sleeping well though! |
The link is: https://github.com/xexyl/sgit/ I might play with a clone rule but we will see. In the end if I do you can modify it to your liking but I might just leave it to you as you have a better idea about the structure of the website. Will try resting again soon. I will reply to your other comments later. |
The creation of the Tool such as Now |
Given comment 1741693358, probably |
Hmmm okay so should both tools be moved over to the tmp/ directory with the log being the explanation you gave in the comment? And then later on the one or both might be in another repo but since I have my sgit repo it might not be needed as if you need it for any other reason (perhaps at some other point in time where mass editing could be useful) you - the judges - can clone it and use it and then make any commits (or if not necessary then don't make commits). Is that correct? If the sgit is ever useful for the website or something else you could always have a Makefile rule that clones it kind of like the mkiocccentry repo clones other repos as well. Does that all seem correct? But either way: do you want me to move both tools to tmp/ or? Also since there will be a need for sgit still what do you want me to do if I make improvements on or other changes (one of which I actually have in mind .. actually I have a couple things I might do)? Thank you! I will be happy to do it when you clarify though I must admit that I am honoured you had the idea of having the tool in the website (though I didn't know why exactly) even if that has proven to be not necessary after all so THANK YOU for that too! I hope you are all better now and that you are sleeping well! I have been awake since about half past two but kind of asleep until three. I doubt that I will be able to sleep more but I will probably try in a bit. No idea what I might get done here today but if I make any changes to sgit I will copy them here. Then when you tell me what you need with both tools I can address that. I actually am going to try and rest now .. hopefully back later. |
Just a reminder to myself: I'll have to update the thanks file too ... modify it to say it was used to update parts of the website easily or something, depending on how it's used. Once we figure out what is desired of course ... |
Sure, the
Correct. So once the UPDATE 0
Yes, as per the above.
Announce it in a CHANGES file, and if you think they are particularly applicable to the |
'Once the copy of What do you mean by the winners repo That sounds like there will be a clone of the Thank you and either way it's a great honour so thank you for that too!
Before I do that though above it sounds like both it cannot be done yet and also that only
Good idea .. I can do that. Maybe backdate some entries too but I'm not sure: depends on how I feel. Not sure that'll be done today or not but I can look into it. Hope you're sleeping well .. I am hoping I can rest again but probably won't sleep again if I can even rest. |
The commit 62d40c1 has completed the action:
|
This is helpful but I'm still unclear on some things. It says installed from but how so? I don't see it. Also I need to know how it's going to be used more than it already has been so I can update the thanks file. It says installed but how will that happen and in what way? Thanks. |
.. ah, maybe by installed you mean that you installed it on your system? If that's the case that's an honour (well it's all been an honour including everything with sgit) but still I'd like to know how the sgit reference in thanks file should be updated. I have some thoughts but I want to know what you're planning on doing too so it can be more accurate. I certainly have used it a fair bit to help with the website but not sure what else to say or how it'll be used in the future. THANK YOU! |
... as for |
You do it: cd /some/where
sgit clone https://github.com/xexyl/sgit.git
cd sgit
make install |
You are most welcome. It is a generally useful tool, that has some advantages over |
Sorry .. I meant what did you mean. Did you do that? Install it on your system? I already have it installed on mine of course. I'm trying to figure out what I should put in the thanks file - or rather change it to. |
Ah. So you do mean you installed it? That is helpful and I'm both honoured and thrilled if that is indeed what you mean. I can update the file tomorrow most likely if that is indeed what you mean? And yes I agree it is quite useful. Thank you. Just reading a bit and then will be shutting laptop down to do other things. Hope you have a great day! |
Yes, the
The selected tool will be driven by a wrapper shell script, something that might pre-process and post-process what the conversion tool does.
Something we plan to do next once calc v2.15.x is released. |
We used it recently with man change in the calc repo. Suggestion: All a |
Very cool! Thanks for telling me. This also will be enough for me update the thanks file too, tomorrow.
So a dry-run option. Hmm ... not sure if that is possible with What kind of errors are you thinking of with Heading off for the day. Thanks for the suggestions and I'll look at it more tomorrow I'm sure! Have a great afternoon! |
Perhaps with no or low You could simple echo the sed command that would be executed without executing them. Perhaps with a higher You could copy the file to a temporary filename, run sed, and remove the temp files afterwards. Perhaps with an even higher You could copy the file to a temporary filename, run sed, diff the result, and remove the temp files afterwards This way if the sed command had a syntax problem, the But in all cases the use of |
Okay these are interesting ideas. I will have to think about them. Maybe sleeping on it will be useful too though I don't have much hope about that. Thanks. Of course if you have motivation and use cases in mind to do it you're certainly welcome to do a pull request. Tomorrow I have several things to do including working on this repo but also a zoom call in the afternoon. Plus I do 'need' to do a bit of reading. But I can start looking at this idea soon anyway I am sure possibly tomorrow even. For now though I better go get ready for bed. Good night and thank you! |
Of course doing one part is very easy: just showing what commands will run. Or it should be. I thought that I already did that but now I think on it I might be mixing it up with the script that I wrote today. Okay so that part should be easy to do probably quickly (with the new option it would not run it but just show what would run and otherwise it would depending on verbosity level show it and do it) but the other parts will probably take a bit more thought. I will look at it soon. Good night! |
Quickly writing this. Just had an idea how to do the temp files. Using the I will sleep on this. Really going now. Thank you for the suggestion and kind words! Good night! |
I did think of a problem or possible problem with this idea of editing files as such as a backup and then doing a diff and ... That problem is that it uses And that way you can merge the other pull request as well. I have another change that needs to be done and I'll try and squeeze in the sgit change too but I will be trying to rest quite soon before some of that. |
Oh .. the script already does show what commands will be run! If verbosity level is >= 1. I can try and look at showing what files will be edited or examined later on. If
This can already be done with the
Though not strictly the same would running What do you think of this? It would simplify things greatly. I might even be able to do it through
If the shell globbing messed up the script might already show it but I'm not sure. What do you mean exactly please? Knowing this would be helpful in implementing it. Perhaps you have an example? Thanks for the suggestions! Time to rest .. well after I fix the version string in the script: noticed a problem. Then rest and then I'll try and look at the adding the Good night (even though it's morning)! :-) UPDATE 0If bash script getops can allow an OPTIONAL arg to an option it might be that |
Initial support for Again also I'm ABSOLUTELY HONOURED that you have installed and used this script not only for this repo (or if not I know you will likely be doing so) but also the calc repo! See commit xexyl/sgit@40872e6. And now it's time to try and rest! Good day! |
BTW: what change or changes exactly did you use sgit for (in calc)? Anyway .. time to try and rest, little hope there is in being able to ... back later to update thanks file and maybe do other things. Hope you're having a nice sleep! |
.. okay made a bug fix in |
Something that is lacking from the man page is that there are no
examples. This is currently being justified by the fact that the
README.md has examples but since that might not always be available this
doesn't hold very well. This will likely be fixed another time when I
have more energy, time and patience for it.
As it is not clear to me how any documentation should be 'installed' I
have not updated the Makefile to address this. That can be done later -
or not for that matter.
The usage string has been improved a bit. There was one thing that could
be more clear and there was something missing too.
Fixed exit codes when command line error.
README.md now refers to the man page and the usage string was updated to
match the usage string change.
New version 0.0.11-1 28-04-2023.