Skip to content

Hotfix/interface files#10

Open
TheRealOwenRees wants to merge 4 commits intoexercism:mainfrom
TheRealOwenRees:hotfix/interface-files
Open

Hotfix/interface files#10
TheRealOwenRees wants to merge 4 commits intoexercism:mainfrom
TheRealOwenRees:hotfix/interface-files

Conversation

@TheRealOwenRees
Copy link
Contributor

  • Auto generate interface files on exercise creation
  • Copy interface files for testing
  • Add interface files to existing exercises

@TheRealOwenRees TheRealOwenRees added the x:rep/small Small amount of reputation label Mar 10, 2026
"exemplar": [
".meta/src/%{pascal_slug}.res"
],
"editor": [
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made a mistake here. https://exercism.org/docs/building/tracks/config-json indicates an editor file is read-only which is not what we want. The interface file will need to go under solution not editor.

Copy link
Contributor Author

@TheRealOwenRees TheRealOwenRees Mar 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

 "example": [
      ".meta/%{pascal_slug}.res",
      ".meta/%{pascal_slug}.resi"
    ],

it is added here, so that it populates the src folder.

If I move the current .resi file out of the editor section, there will be no editor file. Would that be correct?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We want the .resi in example, exemplar, and solution for consistency. That makes the interface file available and most importantly editable in the online editor for students, but also then configlet creates it when adding concept and practice exercises so contributors can have their own interface files for the example/exemplar solutions.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So example/exemplar section is for writable files in the editor, but the editor section is for non-writable files that we still want to show in the editor for reference.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe that this is the case currently. Unless I have missed something. The editor files are created by configlet, and we will need to just change the types on that so the student sees them, and the .resi file should be placed alongside the example file in /src.

It is quite probable that my brain is not full awake.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I see, there is not a .resi file in the exemplar section. Are we using the example as an exemplar solution too? I have not seen this in the wild before.

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

Labels

x:rep/small Small amount of reputation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants