Update readme & history

This commit is contained in:
Buu Nguyen 2016-07-18 10:41:09 -07:00
commit 25fa67c719
7 changed files with 15 additions and 10 deletions

View File

@ -1,3 +1,8 @@
### v2.0.13
* Avoid showing on patch and diff
* Add more reserved names
* Update GitLab token link
### v2.0.12
* Fix issue due to GitLab redesign

View File

@ -32,7 +32,7 @@ __Note__: Firefox 43+ requires add-ons to be signed. Therefore, you should insta
## Settings
### Access Token
__Note for the paranoids (like me!)__: Octotree stores access tokens in your browser local storage and never transmits it anywhere. If you want to verify, check out the source, starting with [this line](https://github.com/buunguyen/octotree/blob/master/src/view.options.js#L77).
__Note for the paranoids (like me!)__: Octotree stores access tokens in your browser local storage and never transmits it anywhere. If you want to verify, check out the source, starting with [this line](https://github.com/buunguyen/octotree/blob/master/src/view.options.js#L77).
#### GitHub
Octotree uses [GitHub API](https://developer.github.com/v3/) to retrieve repository metadata. By default, it makes unauthenticated requests to the GitHub API. However, there are two situations when requests must be authenticated:
@ -43,7 +43,7 @@ Octotree uses [GitHub API](https://developer.github.com/v3/) to retrieve reposit
When that happens, Octotree will ask for your [GitHub personal access token](https://help.github.com/articles/creating-an-access-token-for-command-line-use). If you don't already have one, [create one](https://github.com/settings/tokens/new), then copy and paste it into the textbox. Note that the minimal scopes that should be granted are `public_repo` and `repo` (if you need access to private repositories).
#### GitLab
Octotree uses [GitLab API](http://doc.gitlab.com/ce/api/) to retrieve repository metadata. By default, Octotree attempts to retrieve the access token embedded in the GitLab DOM and use the token to authenticate against the GitLab API. If Octotree cannot retrieve the token, it will prompt you to [create one](https://gitlab.com/profile/account).
Octotree uses [GitLab API](http://doc.gitlab.com/ce/api/) to retrieve repository metadata. By default, Octotree attempts to retrieve the access token embedded in the GitLab DOM and use the token to authenticate against the GitLab API. If Octotree cannot retrieve the token, it will prompt you to [create one](https://gitlab.com/profile/personal_access_tokens).
### Enterprise URLs
By default, Octotree only works on `github.com` and `gitlab.com`. To support enterprise version (Chrome and Opera only), you must grant Octotree sufficient permissions. Follow these steps to do so:

View File

@ -1,6 +1,6 @@
{
"name": "octotree",
"version": "2.0.12",
"version": "2.0.13",
"description": "Code tree for GitHub and GitLab",
"main": "inject.js",
"scripts": {

View File

@ -125,9 +125,9 @@ class GitHub extends Adapter {
return cb()
}
// (username)/(reponame)[/(type)]
const match = window.location.pathname.match(/([^\/]+)\/([^\/]+)(?:\/([^\/]+))?/)
if (!match) {
// (username)/(reponame)[/(type)][.*][.(patch|diff)]
const match = window.location.pathname.match(/([^\/]+)\/([^\/]+)(?:\/([^\/]+))?(?:\/[^.]+)?(?:\.(patch|diff))?$/i)
if (!match || match[4]) {
return cb()
}

View File

@ -1,6 +1,6 @@
{
"name": "Octotree",
"version": "2.0.12",
"version": "2.0.13",
"manifest_version": 2,
"author": "Buu Nguyen",
"description": "Code tree for GitHub and GitLab",

View File

@ -9,7 +9,7 @@
"icon": "resource://jid1-Om7eJGwA1U8Akg-at-jetpack/data/icons/icon48.png",
"icon64": "resource://jid1-Om7eJGwA1U8Akg-at-jetpack/data/icons/icon64.png",
"license": "MIT",
"version": "2.0.12",
"version": "2.0.13",
"permissions": {
"cross-domain-content": ["https://api.github.com", "https://github.com", "https://gitlab.com"],
"private-browsing": true

View File

@ -13,9 +13,9 @@
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleShortVersionString</key>
<string>2.0.12</string>
<string>2.0.13</string>
<key>CFBundleVersion</key>
<string>2.0.12</string>
<string>2.0.13</string>
<key>Chrome</key>
<dict/>
<key>Content</key>