Let me know what you guys think about this:
A couple of thoughts:
-
In the Makefile,
@[ -d "./$(DESTDIR)" ] || rm -fr "./$(DESTDIR)"will only delete the directory if it does not exist. Since you want to create it anyway, just remove the condition:rm -fwill not complain if it does not exist. -
Another Makefile comment: quote the directory, and use bash’s builtin variable
BASENAME = $(shell basename "$$PWD" | sed -r 's/(^|-)([a-z])/\U\2/g')Tests -
The test files should not loop over a collection of test data. For newbies that is adding extra complication. Lay out the tests individually.
Assuming this is valid Pascal
Program TwoFerTests; Uses TAP, TAPCore, TwoFer; Begin Plan(3); TestIs(RunExercise(''), 'One for you, one for me.', 'no name given'); TestIs(RunExercise('Alice'), 'One for Alice, one for me.', 'a name given'); TestIs(RunExercise('Bob'), 'One for Bob, one for me.', 'another name given'); DoneTesting; End. -
bin/verify_exercises – should not check in the compiled binary. Will it run on all platforms that maintainers use? Please add the Makefile and/or instructions to build it. But I like that you’re writing utility programs in the track language.
-
I’d recommend you store all the common files in a central directory. Then, if you need to make a change to them, you can do it in one place and use a script to distribute to all the exercises. We did that in 8th: 8th/libs at main · exercism/8th · GitHub
If the Exercise Community accepts my track approach, it would be better to have a truly agnostic track, focused on the Pascal language only. Therefore, a Pascal Track would be better than Free Pascal Track for this purpose, and Free Pascal for convenience, it would be the chosen implementation for the Pascal Track because it is free and runs on all popular architectures and operating systems. In any case, I don’t intend to continue the work already done in the free-pascal repository, nor would I want it to be deleted. I don’t believe it’s worth messing with the repository because, essentially, it would mean deleting everything, including git configurations, and starting from scratch. That track has dependencies on Lazarus; I even believe it should be called lazarus or lazarus-pascal, for example. Furthermore, a Pascal Track doesn’t rival the Delphi Track or a potential Lazarus Track. The Delphi Track already has its audience and doesn’t need to bother with the Pascal Track.
Truly, there are many things to remodel, polish, and improve! I appreciate your recommendations! I’ll work them.
So you don’t want to continue free-pascal repo minus the Lazarus dependency but instead create a new pascal track repo from scratch?
I think this would be considered a brand-new track request then since you’re not taking over an existing WIP repo. The repo you linked to contains the Hello World! example with tests we ask for. At this stage, @iHiD or @ErikSchierboom would be the ones to decide whether or not to move forward with this as a separate repo.
Yes, but that’s debatable, I’m not demanding it. I just don’t want to overwrite the work already done, nor do I have any interest in Lazarus.
I’m fine with that.
Even if you guys think it’s better to replace actual WIP Free-Pascal with my approach, I’ll do it. I think my only real requirement is to be able to focus purely on Free Pascal. I consider the current Lazarus dependence completely inconsistent for a track named free-pascal, plus I really don’t want to work with Lazarus.
I’ve implemented pretty much all of your suggestions. Some things will make more sense if this project moves forward. Furthermore, I’m sure I’ll have a lot of questions and I’ll need the community’s support often. ![]()