How to share a NetLogo model through GitHub

我的梦境 提交于 2019-12-11 08:49:22

问题


This really helpful question (and answer) works great for sharing a NetLogo model through a public folder in Dropbox.

However, my understanding is that Dropbox will no longer (though for the moment still does) support sharing HTML (and so NetLogo files) this way.

The question and answer above mentioned GitHub, and in particular the URL to the "raw" HTML file, as a potential solution. I tried this but had some problems.

Here's the file hosted via Dropbox (it works) : https://dl.dropboxusercontent.com/u/1190498/Virus%20on%20a%20Network%20(Hinze).html

Here's the identical, I think, (raw) file hosted via GitHub: https://raw.githubusercontent.com/jrosen48/netlogo-models/master/Virus%20on%20a%20Network%20(Hinze).html

Thinking that the key was rendering the HTML, I tried to prepend https://htmlpreview.github.io/? to the file hosted via GitHub, to no avail.

How to share a NetLogo model through GitHub?


回答1:


It's kind of sad that the rules for this keep changing, but I guess there are two things that I could kind of recommend. One is to use the NetLogo Modeling Commons. NLW versions of models uploaded there can be directly linked to, simply by uploading the .nlogo file—that is, you never even need to do "Export: HTML".

The other option—the option that I think I might recommend more strongly is to use GitHub Pages, which is essentially a free, basic web host. You can see here an example of a model that I uploaded to GitHub pages. The setup of the repository is quite trivial; I just made a repo named "[username].github.io", uploaded the exported HTML file, and then it was accessible from a predictable URL.



来源:https://stackoverflow.com/questions/42893176/how-to-share-a-netlogo-model-through-github

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!