Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to reference a file in a GitHub issue? [closed]

In GitHub issues, can I reference a file in the repository directly in the issue and have it auto-link?

like image 572
Justin Avatar asked May 14 '13 03:05

Justin


People also ask

How do I reference a GitHub issue?

You can reference issues between repositories by mentioning user/repository#number in an issue. Once we see something like that — say, github/enterprise#59 — we'll make sure to update issue #59 in github's enterprise repository and let you know where it was referenced from.

How do I reference a PR issue in GitHub?

Under your repository name, click Pull requests. In the list of pull requests, click the pull request that you'd like to link to an issue. In the right sidebar, in the "Development" section click . Click the issue you want to link to the pull request.

How do I reference code in an issue on GitHub?

On GitHub, navigate to the main page of the repository. Locate the code you want to reference in an issue: To open an issue about code in a file, navigate to the file. To open an issue about code in a pull request, navigate to the pull request and click Files changed.

How do I create an issue in GitHub repository?

Creating an issue from a repository 1 On GitHub, navigate to the main page of the repository. 2 Under your repository name, click Issues. 3 Click New issue . 4 If your repository uses issue templates, click Get started next to the type of issue you'd like to open. ... 5 Type a title and description for your issue. More items...

How do I cite a GitHub repository in APA?

How to Cite a GitHub Repository 1 Method 1 of 3: IEEE Download Article. Start your entry with the name of the author of the code. ... 2 Method 2 of 3: ACM Download Article. Start your References entry with the name of the author. ... 3 Method 3 of 3: CSE Download Article. Start your Bibliography entry with the name of the author. ...

How do I include code in a pull request on GitHub?

On GitHub.com, navigate to the main page of the repository. To open an issue about code in a file, navigate to the file. To open an issue about code in a pull request, navigate to the pull request and click Files changed. Then, browse to the file that contains the code you want include in your comment, and click View.


1 Answers

You cannot auto-link to a file, only commits and issues.

Side note, it is better to use a hash when linking to make it “future proof”. Example:

http://github.com/antirez/redis/blob/3244d8b/MANIFESTO 
like image 89
2 revs Avatar answered Nov 09 '22 03:11

2 revs