GitHub source code embedded in my HTML page? [closed] - html

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
I would like to display a code snippet from my own public GitHub source repo in my own web site, without having to make a copy. This is for a tutorial to illustrate some programming concepts. So not to run it but to pretty print it, as it were.
I bet this is something that many people need. I am looking for a lead on how to do this.

You could use the GitHub API to accomplish this.
See the Get Contents endpoint.

Yes, you can do that either by publishing your repo on npm and then referring it as npm dependency in projects package.json.
or 2nd , you can directly refer GitHub repo as dependency in package.json.
Hope this gets you in right direction.
thanks

Related

Problems with the structure of my app in Go [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 2 years ago.
Improve this question
So a week ago I started learning Golang by my own. I wanted to make like a Google drive web application. I learned the basics but there is one thing that I don't understand: project structure.
I searched for information about how to structure your project but I finally got confused because some people say that I have to create something like: github.com/myuser and others that I have to create 3 different folders (bin, cmd and pkg).
Could anyone give me some hints about how to structure my web project? Help is much appreciated.
You can always start small with the MVC pattern. No need to make life anymore complex than it needs to be. I usually start with a models, controllers, views, assets, router, directory and a main.go file. The structure of a project isn't important. What IS important is that YOU can understand your code and know what each section and file does.

How could I deploy a website to the Internet with Jekyll? [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 2 years ago.
Improve this question
I have made a website I really like, but I don't know how to deploy it. I've heard about Jekyll, but anything will work for me. If you have any advice, please share! :)
The most popular and probably easiest way is to use GitHub Pages. Github Pages has built-in Jekyll support and will automatically build your site and serve it to a github.io domain or a custom domain if you set it up.
Jekyll Docs: https://jekyllrb.com/docs/github-pages/
GitHub Pages Docs: https://docs.github.com/en/github/working-with-github-pages/setting-up-a-github-pages-site-with-jekyll
I recently learned about Netlify, which purports to do the same thing as GitHub Pages with some additional features. It has a free tier, and they have a published guide on deploying Jekyll sites: https://www.netlify.com/blog/2020/04/02/a-step-by-step-guide-jekyll-4.0-on-netlify/

Git Like Software [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
I am really thinking of how I can build a very minimal Git-like software only for my self for now!
I have gone through Git documentations and even the way git works and I have quite an understanding on it.
Is there any example for me to study as a bonus before I dive into this project?.
In addition to the Documentation/technical folder which explains the internals of Git, you can study how Git was re-implemented, as an exercice, in other languages.
See for instance:
in Go the project src-d/go-git (recent 2018),
in Javascript: danlucraft/git.js (much older),
In Javascript (more recent 2015): Gitlet.
In Java, the project eclipse/jgit (used by EGit)
In C (with a lot of bindings for other languages), LibGit2 (and its GitHub repository, apologies to Edward Thomson for not mentioning it first.)

Notepad v.s. other platforms [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
Lately i have been using Notepad ++ and i was wondering if any of y'all would recommend a different platform that would allow me and another person to code on the same project at the same time?
I like using Sublime text.
It's very lightweight and extemely versatile :).
You can install alot of free very creative plugins to help you coding too including some SVN plugins.
To share your code another way i guess you could use something like github or tortoise SVN too.
To work on thesame file online i recommend collabedit.com (Online editor for multiple users)
Good luck
Er, well, you could try Vim or Aptana Studio or Net Beans?

Etiquette of GitHub Contributing, Pull Requests vs New Issue [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
I was wondering what the proper etiquette to contributing on GitHub is?
Should you submit a "New Issue" first and discuss the problem?
Or do you take some initiative, code, then do a "Pull Request" and discuss the code further there?
My concern with creating a "New Issue" first is that if you do a "Pull Request" after, there would be two issues #'s created... seems like a waste.
Thanks!
The difference is quite clear:
if you don't think you can contribute back a patch, open a new issue (following the same kind of checklist than the one described here).
if you think you can make some patch to fix the issue, fork the repo, and make a pull request (once you have pushed your patch back to your fork).
If you make a pull issue first, and then create a pull request, nothing stops you to reference the issue URL in your pull request comment, in order to avoid writing again the context of your patch.