Skip to content
This repository was archived by the owner on Sep 1, 2021. It is now read-only.

Commit eb98f7b

Browse files
committed
remove old resources, do some renames and update readme
1 parent b35397a commit eb98f7b

File tree

84 files changed

+35
-754
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

84 files changed

+35
-754
lines changed

README.md

Lines changed: 34 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ the Bookmarks and Code Snippets Manager for Developers & Co.
66
## Install
77
This browser extension is available for:
88

9-
| ![Chrome](docs/img/logo/chrome-48.png) | ![Firefox](docs/img/logo/fx-48.png) |
9+
| ![Chrome](resources/img/logo/chrome-48.png) | ![Firefox](resources/img/logo/fx-48.png) |
1010
|:---:|:---:|
1111
| [Chrome](TODO-add-link-to-google-store) | ![Firefox](TODO-add-link-to-firefox-store) |
1212

@@ -18,7 +18,7 @@ Select code snippet && (right click || click on extension icon) to save it to [B
1818

1919
A popup window is launched where you can add additional metadata to the code snippet record.
2020

21-
![Chrome extension screenshot](docs/img/gif/gif-save-snippet-via-chrome-extension-800.gif)
21+
![Chrome extension screenshot](assets/images/save-snippet-via-chrome-extension-800.gif)
2222

2323
> You need to have an account to save code to your code snippets
2424
@@ -27,24 +27,40 @@ A popup window is launched where you can add additional metadata to the code sni
2727
## Testing locally
2828
Check out the git repository - `git clone https://github.com/BookmarksDev/code-snippets-browser-extension`
2929

30-
### Chrome
30+
### Chrome/Brave
3131
Go to [chrome://extensions/](chrome://extensions/), click **Load unpacked** and select the `code-snippets-browser-extension` folder
3232
where you have checked it out:
3333

34-
![Install locally on chrome](docs/img/install-locally-and-reload-extension.png)
34+
![Install locally on chrome](assets/images/install-locally-and-reload-extension-chrome.png)
3535

3636
> Click "Reload" on the extension when you do modifications
3737
38-
### Firefox
38+
###
39+
#### Use [web-ext](https://github.com/mozilla/web-ext)
40+
The easiest way is to use [web-ext](https://github.com/mozilla/web-ext)
41+
You can install it globally for example via
42+
```
43+
npm install --global web-ext
44+
```
45+
and then run the following command in the root directory of the project
46+
47+
```
48+
web-ext run
49+
```
50+
51+
This installs "Save code to Bookmarks.dev" as a temporary add-on and it watches for changes in the source code
52+
and **redploys automatically**.
53+
54+
#### Manual deployment
3955
Go to [about:debugging#/runtime/this-firefox](about:debugging#/runtime/this-firefox), click **Load Temporary Add-on...**
40-
and select the `manifest.json` file from the `save-code-to-bookmarks.dev-browser-extension` folder where you have checked it out:
56+
and select the `manifest.json` file from the `code-snippets-browser-extension` folder where you have checked it out:
4157

42-
![Install locally on Firefox](docs/img/install-locally-and-reload-extension.png)
58+
![Install locally on Firefox](assets/images/install-locally-and-reload-extension-firefox.png)
4359

4460
> Click "Reload" on the extension when you do modifications
4561
4662
### Test the extension against the [`localhost`](https://github.com/BookmarksDev/bookmarks.dev) version of Bookmarks.dev
47-
Change the following line in [launch-bookmarksdev-dialog.js](launch-bookmarksdev-dialog.js):
63+
Change the `host` url in the following line from [launch-bookmarksdev-dialog.js](launch-bookmarksdev-dialog.js):
4864
```
4965
const url = 'https://www.bookmarks.dev/my-codelets/new?sourceUrl=' + encodeURIComponent(l) + '&code=' + encodeURIComponent(d) + '&title=' + encodeURIComponent(t) + '&popup=true'
5066
```
@@ -53,17 +69,22 @@ to
5369
const url = 'http://localhost:4200/my-codelets/new?sourceUrl=' + encodeURIComponent(l) + '&code=' + encodeURIComponent(d) + '&title=' + encodeURIComponent(t) + '&popup=true'
5470
```
5571

56-
and Reload the extension
72+
and then Reload the extension with one of the mechanisms mentioned before
5773

5874
## Publish browser extension to official stores
5975

60-
### Publish to Google Chrome Webstore
76+
First of all zip the file either with `web-ext`
77+
```
78+
web-ext build -i 'docs'
79+
```
6180

62-
First of all package it as a zip file:
63-
```shell
64-
zip -r bookmarks.dev.chrome.extension.zip * -x *.idea* *.git* '*docs/*' "*README.md*"
81+
or with _standard_ `zip` command:
6582
```
83+
zip -r releases/code-snippets.bookmarks.dev.chrome.extension.zip * -x *.idea* *.git* '*resources/*' '*web-ext-artifacts/*'
84+
```
85+
6686

87+
### Publish to Google Chrome Webstore
6788
Go to [Chrome Webstore Dashboard](https://chrome.google.com/webstore/developer/dashboard) where
6889
you upload the .zip file. Wait for a couple of business days for an approval.
6990

-611 KB
Binary file not shown.
-2.64 MB
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
-617 KB
Binary file not shown.

docs/img/codelet.dev.logo.xcf

-617 KB
Binary file not shown.
Binary file not shown.

0 commit comments

Comments
 (0)