-
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add rules for checking package index filename
The package index filename must follow a specific format. Package indexes which are not compliant are ignored by the Arduino development software. Only the official package index may be named package_index.json.
- Loading branch information
Showing
6 changed files
with
234 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
51 changes: 51 additions & 0 deletions
51
...rule/rulefunction/testdata/packageindexes/3rd-party-filename/package_3rd-party_index.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
{ | ||
"packages": [ | ||
{ | ||
"name": "notarduino", | ||
"maintainer": "NotArduino", | ||
"websiteURL": "http://www.arduino.cc/", | ||
"email": "packages@arduino.cc", | ||
"help": { | ||
"online": "http://www.arduino.cc/en/Reference/HomePage" | ||
}, | ||
"platforms": [ | ||
{ | ||
"name": "Arduino AVR Boards", | ||
"architecture": "avr", | ||
"version": "1.8.3", | ||
"category": "Contributed", | ||
"help": { | ||
"online": "http://www.arduino.cc/en/Reference/HomePage" | ||
}, | ||
"url": "http://downloads.arduino.cc/cores/avr-1.8.3.tar.bz2", | ||
"archiveFileName": "avr-1.8.3.tar.bz2", | ||
"checksum": "SHA-256:de8a9b982477762d3d3e52fc2b682cdd8ff194dc3f1d46f4debdea6a01b33c14", | ||
"size": "4941548", | ||
"boards": [{ "name": "Arduino Uno" }], | ||
"toolsDependencies": [ | ||
{ | ||
"packager": "arduino", | ||
"name": "avr-gcc", | ||
"version": "7.3.0-atmel3.6.1-arduino7" | ||
} | ||
] | ||
} | ||
], | ||
"tools": [ | ||
{ | ||
"name": "avr-gcc", | ||
"version": "7.3.0-atmel3.6.1-arduino7", | ||
"systems": [ | ||
{ | ||
"size": "34683056", | ||
"checksum": "SHA-256:3903553d035da59e33cff9941b857c3cb379cb0638105dfdf69c97f0acc8e7b5", | ||
"host": "arm-linux-gnueabihf", | ||
"archiveFileName": "avr-gcc-7.3.0-atmel3.6.1-arduino7-arm-linux-gnueabihf.tar.bz2", | ||
"url": "http://downloads.arduino.cc/tools/avr-gcc-7.3.0-atmel3.6.1-arduino7-arm-linux-gnueabihf.tar.bz2" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
} |
51 changes: 51 additions & 0 deletions
51
internal/rule/rulefunction/testdata/packageindexes/invalid-filename/invalid-filename.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
{ | ||
"packages": [ | ||
{ | ||
"name": "notarduino", | ||
"maintainer": "NotArduino", | ||
"websiteURL": "http://www.arduino.cc/", | ||
"email": "packages@arduino.cc", | ||
"help": { | ||
"online": "http://www.arduino.cc/en/Reference/HomePage" | ||
}, | ||
"platforms": [ | ||
{ | ||
"name": "Arduino AVR Boards", | ||
"architecture": "avr", | ||
"version": "1.8.3", | ||
"category": "Contributed", | ||
"help": { | ||
"online": "http://www.arduino.cc/en/Reference/HomePage" | ||
}, | ||
"url": "http://downloads.arduino.cc/cores/avr-1.8.3.tar.bz2", | ||
"archiveFileName": "avr-1.8.3.tar.bz2", | ||
"checksum": "SHA-256:de8a9b982477762d3d3e52fc2b682cdd8ff194dc3f1d46f4debdea6a01b33c14", | ||
"size": "4941548", | ||
"boards": [{ "name": "Arduino Uno" }], | ||
"toolsDependencies": [ | ||
{ | ||
"packager": "arduino", | ||
"name": "avr-gcc", | ||
"version": "7.3.0-atmel3.6.1-arduino7" | ||
} | ||
] | ||
} | ||
], | ||
"tools": [ | ||
{ | ||
"name": "avr-gcc", | ||
"version": "7.3.0-atmel3.6.1-arduino7", | ||
"systems": [ | ||
{ | ||
"size": "34683056", | ||
"checksum": "SHA-256:3903553d035da59e33cff9941b857c3cb379cb0638105dfdf69c97f0acc8e7b5", | ||
"host": "arm-linux-gnueabihf", | ||
"archiveFileName": "avr-gcc-7.3.0-atmel3.6.1-arduino7-arm-linux-gnueabihf.tar.bz2", | ||
"url": "http://downloads.arduino.cc/tools/avr-gcc-7.3.0-atmel3.6.1-arduino7-arm-linux-gnueabihf.tar.bz2" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
} |
51 changes: 51 additions & 0 deletions
51
internal/rule/rulefunction/testdata/packageindexes/official-filename/package_index.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
{ | ||
"packages": [ | ||
{ | ||
"name": "arduino", | ||
"maintainer": "Arduino", | ||
"websiteURL": "http://www.arduino.cc/", | ||
"email": "packages@arduino.cc", | ||
"help": { | ||
"online": "http://www.arduino.cc/en/Reference/HomePage" | ||
}, | ||
"platforms": [ | ||
{ | ||
"name": "Arduino AVR Boards", | ||
"architecture": "avr", | ||
"version": "1.8.3", | ||
"category": "Arduino", | ||
"help": { | ||
"online": "http://www.arduino.cc/en/Reference/HomePage" | ||
}, | ||
"url": "http://downloads.arduino.cc/cores/avr-1.8.3.tar.bz2", | ||
"archiveFileName": "avr-1.8.3.tar.bz2", | ||
"checksum": "SHA-256:de8a9b982477762d3d3e52fc2b682cdd8ff194dc3f1d46f4debdea6a01b33c14", | ||
"size": "4941548", | ||
"boards": [{ "name": "Arduino Uno" }], | ||
"toolsDependencies": [ | ||
{ | ||
"packager": "arduino", | ||
"name": "avr-gcc", | ||
"version": "7.3.0-atmel3.6.1-arduino7" | ||
} | ||
] | ||
} | ||
], | ||
"tools": [ | ||
{ | ||
"name": "avr-gcc", | ||
"version": "7.3.0-atmel3.6.1-arduino7", | ||
"systems": [ | ||
{ | ||
"size": "34683056", | ||
"checksum": "SHA-256:3903553d035da59e33cff9941b857c3cb379cb0638105dfdf69c97f0acc8e7b5", | ||
"host": "arm-linux-gnueabihf", | ||
"archiveFileName": "avr-gcc-7.3.0-atmel3.6.1-arduino7-arm-linux-gnueabihf.tar.bz2", | ||
"url": "http://downloads.arduino.cc/tools/avr-gcc-7.3.0-atmel3.6.1-arduino7-arm-linux-gnueabihf.tar.bz2" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
} |