Sublime-GitHubFileFetcher

GitHubFileFetcher

GitHubFileFetcher icon

GitHubFileFetcher is a Sublime Text package that searches and fetches files from GitHub.

RepositoryGitHubSublime Text
GitHub release (latest by date)GitHub open issues GitHub closed issuesPackage Control Total
GitHub licenseGitHub pull requests GitHub closed pull requestsPackage Control Month
GitHub language countGitHub contributorsPackage Control Week
GitHub code size in bytesGitHub downloadsPackage Control Day
Status
GitHub commits since tagged version GitHub Workflow Lint GitHub Workflow Pages

Feature

The following steps are performed one after the other.

1. GitHubFileFetcher (1/6): Fetching GitHub repositories.

1
2
This function allows you to search for GitHub owners or GitHub repositories.
The search results (owner/repository) are then displayed.

2. GitHubFileFetcher (2/6): Fetching branches.

1
After selecting the repository, all possible branches are displayed.

3. GitHubFileFetcher (3/6): Fetching files.

1
After that, select the desired file.

4. GitHubFileFetcher (4/6): Fetching destination folder.

1
Pick the workspace folder where the file should be written. At least one folder must be open in the window; otherwise an error dialog is shown instead of crashing.

5. GitHubFileFetcher (5/6): Enter or change destination file path…

1
Enter or change destination file path.

6. GitHubFileFetcher (6/6): Added file.

1
`Hocus Pocus` - The file was created at the desired location. File content is fetched from the GitHub API (URL-encoded paths, UTF-8 decode with replacement for non-text bytes).

Failed GitHub requests (for example 403 rate limit, 404, or connection errors) show an error dialog with HTTP status when available and stop the workflow cleanly.

GitHubFileFetcher: Should I save the new repository in the settings?

1
2
So that you don't have to search for the repositories again and again,
you can save the currently used one in the settings.

Shortcut: strg + alt + k, f
Command: GitHubFileFetcher: Searches and fetches files from GitHub.

GitHubFileFetcher

Settings

Preferences → Package Settings → GitHubFileFetcher → Settings

NameDescriptionDefault Value
information_messagesStatus output: "false", "true", or "verbose"."true"
github_usernameGitHub username for authenticated API requests.""
github_tokenGitHub personal access token.""
repositoriesSaved repositories as {owner}/{repo}.["dennykorsukewitz/Sublime-GitHubFileFetcher"]

The GitHub API is limited to 60 requests per hour for non authorized requests. You can provide your GitHub username and an access token to push this limit to 5000 requests per hour. Please see the official GitHub doc for further information. You can generate the access token in your GitHub settings.


Installation

To install this package, you have three options:

1. Search Package via Package Control

Search and install via GitHub File Fetcher on Package Control.

Tools -> Command Palette -> Package Control: Install Package -> search for GitHub File Fetcher (or GitHubFileFetcher).

2. Install via sublime-package file

Download latest sublime-package file and move the package GitHubFileFetcher.sublime-package to Installed Packages folder.

OSX

cd ~/Library/Application\ Support/Sublime\ Text\ 2/Installed Packages/

  • or ST 3 - cd ~/Library/Application\ Support/Sublime\ Text\ 3/Installed Packages/

Linux

cd ~/.config/sublime-text-2/Installed Packages

  • or ST 3 - cd ~/.config/sublime-text-3/Installed Packages

Windows

cd “%APPDATA%\Sublime Text 2\Installed Packages”

  • or ST 3 - cd “%APPDATA%\Sublime Text 3\Installed Packages”

3. Source code

Clone the latest dev branch and unpack it to Sublime Package folder Packages.

OSX

cd ~/Library/Application\ Support/Sublime\ Text\ 2/Packages/

  • or ST 3 - cd ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/ git clone git@github.com:dennykorsukewitz/Sublime-GitHubFileFetcher.git GitHubFileFetcher

Linux

cd ~/.config/sublime-text-2/Packages

  • or ST 3 - cd ~/.config/sublime-text-3/Packages git clone git@github.com:dennykorsukewitz/Sublime-GitHubFileFetcher.git GitHubFileFetcher

Windows

cd “%APPDATA%\Sublime Text 2\Packages”

  • or ST 3 - cd “%APPDATA%\Sublime Text 3\Packages” git clone git@github.com:dennykorsukewitz/Sublime-GitHubFileFetcher.git GitHubFileFetcher

Download

For download see Sublime-GitHubFileFetcher


Enjoy!

Your Denny Korsukéwitz 🚀