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

add: Fortran Playground Code links #184

Merged
merged 13 commits into from Aug 13, 2023
Merged

Conversation

henilp105
Copy link
Member

@henilp105 henilp105 commented Oct 7, 2022

This PR is to add The fortran playground links to every fortran code in the learn section. I have currently not added the links to intrinsics as feature is in testing phase.

Resolves:

Thanks and Regards,
Henil

CC @awvwgk @milancurcic

@henilp105
Copy link
Member Author

#build_preview

@github-actions
Copy link

github-actions bot commented Oct 7, 2022

This PR has been built with Sphinx and can be previewed at: https://fortran-lang.github.io/webpage/pr/184

@henilp105
Copy link
Member Author

henilp105 commented Oct 7, 2022

@milancurcic sir, I have Reworded the link, removed logo and added open link in a new tab. We won't be able to add it below as I have added a node with link in the caption using doc util nodes of sphinx.

@zmoon
Copy link
Member

zmoon commented Oct 7, 2022

Couldn't the ones that wouldn't compile just be left as ```fortran?

@henilp105
Copy link
Member Author

@zmoon I had intended to do that , but it would be difficult to detect them, may be at every compilation we would have to run all the codeblocks using gh action .

@zmoon
Copy link
Member

zmoon commented Oct 7, 2022

at every compilation we would have to run all the codeblocks using gh action

I think that seems like a cool idea, maybe you could build something around that.

But I think currently, many of the code blocks are meant to be taken as part of a larger context, so maybe we wouldn't want links for those anyway unless it could be to the full context. That is, the number of "complete" ones is perhaps relatively few at this point, maybe could be identified manually.

#183 (comment)

@henilp105
Copy link
Member Author

@awvwgk @zmoon @milancurcic Would like to request review , I have added functionality to only show link in those (mostly) who run successfully in Playground. Although I had also considered gh action but for the time implementation it seemed most apt . It would also increase build time by ~2.5mins. (for all 11 builds).

@henilp105
Copy link
Member Author

#build_preview

@github-actions
Copy link

github-actions bot commented Oct 8, 2022

This PR has been built with Sphinx and can be previewed at: https://fortran-lang.github.io/webpage/pr/184

@henilp105
Copy link
Member Author

#build_preview

@henilp105
Copy link
Member Author

#build_preview

@github-actions
Copy link

github-actions bot commented Oct 8, 2022

This PR has been built with Sphinx and can be previewed at: https://fortran-lang.github.io/webpage/pr/184

@henilp105
Copy link
Member Author

@awvwgk @milancurcic @zmoon would like to request review of this implementation.

Thanks and Regards,
Henil

Copy link
Member

@zmoon zmoon left a comment

Choose a reason for hiding this comment

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

Added a few comments, but also wondering two things:

  • could the check against Playground be done for only one of the 11 builds and the data cached, to speed up the other builds (or am I misinterpreting?)?
  • if all Fortran code blocks are to be checked, would it possible to patch or hook into CodeBlock itself instead of creating a new directive, so that the code blocks could be left as standard ```fortran @awvwgk ?

source/conf.py Outdated Show resolved Hide resolved
fortran_playground/fortran_playground.py Outdated Show resolved Hide resolved
fortran_playground/fortran_playground.py Outdated Show resolved Hide resolved
fortran_playground/fortran_playground.py Outdated Show resolved Hide resolved
fortran_playground/fortran_playground.py Outdated Show resolved Hide resolved
henilp105 and others added 2 commits October 10, 2022 22:22
Co-authored-by: Zachary Moon <zmoon92@gmail.com>
@henilp105
Copy link
Member Author

#build_preview

@github-actions
Copy link

This PR has been built with Sphinx and can be previewed at: https://fortran-lang.github.io/webpage/pr/184

@henilp105
Copy link
Member Author

@awvwgk @zmoon I have added the changes would like to request review.

Thanks and Regards,
Henil

@henilp105
Copy link
Member Author

#build_preview

@github-actions
Copy link

This PR has been built with Sphinx and can be previewed at: https://fortran-lang.github.io/webpage/pr/184

@henilp105 henilp105 requested review from zmoon and awvwgk August 13, 2023 10:16
Copy link
Member

@awvwgk awvwgk left a comment

Choose a reason for hiding this comment

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

Let's merge this.

@awvwgk awvwgk merged commit 8a46fc6 into fortran-lang:main Aug 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants