diff options
Diffstat (limited to 'support/doc/plugins')
-rw-r--r-- | support/doc/plugins/guide.md | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/support/doc/plugins/guide.md b/support/doc/plugins/guide.md index c5e3236ca..73f58330c 100644 --- a/support/doc/plugins/guide.md +++ b/support/doc/plugins/guide.md | |||
@@ -947,13 +947,13 @@ Steps: | |||
947 | If you develop a plugin, clone the `peertube-plugin-quickstart` repository: | 947 | If you develop a plugin, clone the `peertube-plugin-quickstart` repository: |
948 | 948 | ||
949 | ``` | 949 | ``` |
950 | $ git clone https://framagit.org/framasoft/peertube/peertube-plugin-quickstart.git peertube-plugin-mysupername | 950 | git clone https://framagit.org/framasoft/peertube/peertube-plugin-quickstart.git peertube-plugin-mysupername |
951 | ``` | 951 | ``` |
952 | 952 | ||
953 | If you develop a theme, clone the `peertube-theme-quickstart` repository: | 953 | If you develop a theme, clone the `peertube-theme-quickstart` repository: |
954 | 954 | ||
955 | ``` | 955 | ``` |
956 | $ git clone https://framagit.org/framasoft/peertube/peertube-theme-quickstart.git peertube-theme-mysupername | 956 | git clone https://framagit.org/framasoft/peertube/peertube-theme-quickstart.git peertube-theme-mysupername |
957 | ``` | 957 | ``` |
958 | 958 | ||
959 | ### Configure your repository | 959 | ### Configure your repository |
@@ -961,8 +961,8 @@ $ git clone https://framagit.org/framasoft/peertube/peertube-theme-quickstart.gi | |||
961 | Set your repository URL: | 961 | Set your repository URL: |
962 | 962 | ||
963 | ``` | 963 | ``` |
964 | $ cd peertube-plugin-mysupername # or cd peertube-theme-mysupername | 964 | cd peertube-plugin-mysupername # or cd peertube-theme-mysupername |
965 | $ git remote set-url origin https://your-git-repo | 965 | git remote set-url origin https://your-git-repo |
966 | ``` | 966 | ``` |
967 | 967 | ||
968 | ### Update README | 968 | ### Update README |
@@ -970,7 +970,7 @@ $ git remote set-url origin https://your-git-repo | |||
970 | Update `README.md` file: | 970 | Update `README.md` file: |
971 | 971 | ||
972 | ``` | 972 | ``` |
973 | $ $EDITOR README.md | 973 | $EDITOR README.md |
974 | ``` | 974 | ``` |
975 | 975 | ||
976 | ### Update package.json | 976 | ### Update package.json |
@@ -1100,19 +1100,19 @@ If you added client scripts, you'll need to build them using webpack. | |||
1100 | Install webpack: | 1100 | Install webpack: |
1101 | 1101 | ||
1102 | ``` | 1102 | ``` |
1103 | $ npm install | 1103 | npm install |
1104 | ``` | 1104 | ``` |
1105 | 1105 | ||
1106 | Add/update your files in the `clientFiles` array of `webpack.config.js`: | 1106 | Add/update your files in the `clientFiles` array of `webpack.config.js`: |
1107 | 1107 | ||
1108 | ``` | 1108 | ``` |
1109 | $ $EDITOR ./webpack.config.js | 1109 | $EDITOR ./webpack.config.js |
1110 | ``` | 1110 | ``` |
1111 | 1111 | ||
1112 | Build your client files: | 1112 | Build your client files: |
1113 | 1113 | ||
1114 | ``` | 1114 | ``` |
1115 | $ npm run build | 1115 | npm run build |
1116 | ``` | 1116 | ``` |
1117 | 1117 | ||
1118 | You built files are in the `dist/` directory. Check `package.json` to correctly point to them. | 1118 | You built files are in the `dist/` directory. Check `package.json` to correctly point to them. |
@@ -1129,31 +1129,31 @@ You'll need to have a local PeerTube instance: | |||
1129 | * Build PeerTube: | 1129 | * Build PeerTube: |
1130 | 1130 | ||
1131 | ``` | 1131 | ``` |
1132 | $ npm run build | 1132 | npm run build |
1133 | ``` | 1133 | ``` |
1134 | 1134 | ||
1135 | * Build the CLI: | 1135 | * Build the CLI: |
1136 | 1136 | ||
1137 | ``` | 1137 | ``` |
1138 | $ npm run setup:cli | 1138 | npm run setup:cli |
1139 | ``` | 1139 | ``` |
1140 | 1140 | ||
1141 | * Run PeerTube (you can access to your instance on `localhost:9000`): | 1141 | * Run PeerTube (you can access to your instance on `localhost:9000`): |
1142 | 1142 | ||
1143 | ``` | 1143 | ``` |
1144 | $ NODE_ENV=dev npm start | 1144 | NODE_ENV=dev npm start |
1145 | ``` | 1145 | ``` |
1146 | 1146 | ||
1147 | * Register the instance via the CLI: | 1147 | * Register the instance via the CLI: |
1148 | 1148 | ||
1149 | ``` | 1149 | ``` |
1150 | $ node ./dist/server/tools/peertube.js auth add -u 'http://localhost:9000' -U 'root' --password 'test' | 1150 | node ./dist/server/tools/peertube.js auth add -u 'http://localhost:9000' -U 'root' --password 'test' |
1151 | ``` | 1151 | ``` |
1152 | 1152 | ||
1153 | Then, you can install or reinstall your local plugin/theme by running: | 1153 | Then, you can install or reinstall your local plugin/theme by running: |
1154 | 1154 | ||
1155 | ``` | 1155 | ``` |
1156 | $ node ./dist/server/tools/peertube.js plugins install --path /your/absolute/plugin-or-theme/path | 1156 | node ./dist/server/tools/peertube.js plugins install --path /your/absolute/plugin-or-theme/path |
1157 | ``` | 1157 | ``` |
1158 | 1158 | ||
1159 | ### Publish | 1159 | ### Publish |
@@ -1161,7 +1161,7 @@ $ node ./dist/server/tools/peertube.js plugins install --path /your/absolute/plu | |||
1161 | Go in your plugin/theme directory, and run: | 1161 | Go in your plugin/theme directory, and run: |
1162 | 1162 | ||
1163 | ``` | 1163 | ``` |
1164 | $ npm publish | 1164 | npm publish |
1165 | ``` | 1165 | ``` |
1166 | 1166 | ||
1167 | Every time you want to publish another version of your plugin/theme, just update the `version` key from the `package.json` | 1167 | Every time you want to publish another version of your plugin/theme, just update the `version` key from the `package.json` |
@@ -1179,7 +1179,7 @@ If for a particular reason you don't want to maintain your plugin/theme anymore | |||
1179 | you can deprecate it. The plugin index will automatically remove it preventing users to find/install it from the PeerTube admin interface: | 1179 | you can deprecate it. The plugin index will automatically remove it preventing users to find/install it from the PeerTube admin interface: |
1180 | 1180 | ||
1181 | ```bash | 1181 | ```bash |
1182 | $ npm deprecate peertube-plugin-xxx@"> 0.0.0" "explain here why you deprecate your plugin/theme" | 1182 | npm deprecate peertube-plugin-xxx@"> 0.0.0" "explain here why you deprecate your plugin/theme" |
1183 | ``` | 1183 | ``` |
1184 | 1184 | ||
1185 | ## Plugin & Theme hooks/helpers API | 1185 | ## Plugin & Theme hooks/helpers API |