How to publish from a different repo in GitHub pages - github

If I have an HTML project repo in GitHub, can I use my GitHub pages (which is a different repo) to publish it?
Is this article applicable for my requirement?

Related

How do I hide my github profile subdomain repository?

Every github profile/organization has it's custom subdomain which is username.github.io. In order to customize and publish it to github pages we needs to make it's repository which is named exactly the same username.github.io's visibility to public. But I've seen that people are hiding this repository, even from the repository tab but still publishing the page. How to do this?
It is only possible with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server.

GitHub Pages publishing from master vs master/docs or gh-pages branch

I've been able to publish GitHub sites under my domain on GitHub Pages from the master branch without issue, however in the docs it says to use a gh-pages branch or master/docs for publishing projects.
I also have a repository for my homepage index.html file/assets, where I link to each of the published GitHub repositories (which are published to my domain name.com/repo-name).
Why have I been able to publish from the master branch? Is there any reason to publish from the gh-pages branch or master/docs instead for publishing project repositories?
GitHub Pages can publish from any of those sources: gh-pages branch, master/docs, or just from the repo itself. It's more of a preference which route you use.
For example, Jekyll is publishing using the master/docs option. The rest of the repo outside of the docs folder is for the actual Jekyll code. One possible reason is that PR's with new features must also include documentation of that new feature. Otherwise, it won't get merged.
The gh-pages option means that code and documentation can be paced or managed differently. They live in the same repo, but the branches can grow at differing speeds.
In terms of technical differences, there's no technical costs/benefits to each option as far as I know. It's just how you want to organize your code and documentation.
Hope that helps!
GitHub requires user and organization sites to build from master, while project sites can build from gh-pages. If I understand correctly, you are publishing to your user site, i.e. yourusername.github.io.

github Repository removal/deletion & github pages

If I remove/delete a public repository on gitHub, will it remove all of its clones as well? Secondly I want to share my gaming portfolio on github pages is there any way of doing that without having my repositorys cloned?
If you delete the repo from the GH site, it won't remove any clones created on local machines. It will delete everything on the site repository. You can configure GitHub Pages to publish your site's source files from any of these branches: master, gh-pages, or a /docs folder on your master branch. I'd check out this article, since it explains the details.

How to access Github Wiki Branches

I am able to access Github Wiki pages directly using the below URL:
https://raw.githubusercontent.com/wiki/Siminov/android-core/Preface.md
But if I create a branch of master Github Wiki then how to access those pages?
Non-master branches of GitHub wikis are not available through the web interface:
Once you have cloned the wiki, you can add new files, edit existing ones, and commit your changes. You and your collaborators can create branches when working on wikis, but only changes pushed to the master branch will be made live and available to your readers.
The only way to access them is via the wiki repository using whatever software you prefer for working with Git.

jekyll website not updating on github pages

I recently played around with the Jekyll/Poole/Lanyon theme for a new blog. At first, I linked my domain jonathancharleslee.com to my github pages site at jonathancharleslee.github.io
When I update files locally, I can update site features and posts - however, when I push to github it won't update on jonathancharleslee.github.io
Any help is much appreciated.
You're on a user/organisation repository (username.github.io). This type of repository needs you to push in master branch, not in gh-pages.
See Github Pages doc
You should be working and making all your changes on the development branch, then pushing ONLY your built files to the master branch, which is what Github Pages will publish.
There's step-by-step instructions on how to do this in this posting:
https://stackoverflow.com/a/44296933/7669275