Compare commits

...

9 Commits

Author SHA1 Message Date
Crovaxon 519c2d24f2 Change version, download and manifest to Foundry invalid values for testing. 2025-05-11 16:19:49 +02:00
Farling e74ec2b733 Update README.md
Provide example of relationships.requires for other modules to use.
2025-05-09 17:38:36 +01:00
farling42 212297bcc9 Change module.json to work with old location of socketlib 2025-05-09 17:14:35 +01:00
farling42 46f9703989 Revert "Update module.json"
This reverts commit 1b657b463d.
2025-05-09 17:03:29 +01:00
farling42 1b657b463d Update module.json 2025-03-27 22:11:15 +00:00
farling42 c17402a551 Update module.json 2025-03-27 21:58:29 +00:00
farling42 970e99ff92 Update module.json 2025-03-27 21:57:51 +00:00
farling42 ce19c69086 Update module.json 2025-03-27 21:55:18 +00:00
farling42 d2f5edf38e Store hardcoded manifest link in module.json
Older versions use an explicit pointer to module.json in the source tree rather than the version on each release.
2025-03-27 21:52:49 +00:00
3 changed files with 25 additions and 28 deletions
+7 -26
View File
@@ -72,36 +72,17 @@ jobs:
- name: Checkout Repository - name: Checkout Repository
uses: actions/checkout@v4 uses: actions/checkout@v4
# Substitute the Manifest and Download URLs in the module.json
# Extract version embedded in the tag. - name: Substitute Manifest and Download Links For Versioned Ones
# This step expects the tag to be one of the following formats:
# - "v<major>.<minor>.<patch>" (e.g., "v1.2.3")
# - "<major>.<minor>.<patch>" (e.g., "1.2.3")
#
# The version will be used by later steps to fill in the value for the
# "version" key required for a valid module manifest.
- name: Extract Version From Tag
id: get_version
uses: battila7/get-version-action@v2
# Modify "module.json" with values specific to the release.
# Since the values for the "version" and "url" keys aren't known ahead of
# time, the manifest file in the repository is updated with these values.
#
# While this does modify the manifest file in-place, the changes are not
# commited to the repository, and only exist in the action's filesystem.
- name: Modify Module Manifest With Release-Specific Values
id: sub_manifest_link_version id: sub_manifest_link_version
uses: cschleiden/replace-tokens@v1 uses: microsoft/variable-substitution@v1
with: with:
files: 'module.json' files: 'module.json'
env: env:
VERSION: ${{steps.get_version.outputs.version-without-v}} version: ${{github.event.release.tag_name}}
URL: ${{ env.project_url }} url: https://github.com/${{github.repository}}
MANIFEST: ${{ env.latest_manifest_url }} manifest: https://github.com/${{github.repository}}/releases/latest/download/module.json
DOWNLOAD: ${{ env.release_module_url }} download: https://github.com/${{github.repository}}/releases/download/${{github.event.release.tag_name}}/module.zip
# Create a "module.zip" archive containing all the module's required files. # Create a "module.zip" archive containing all the module's required files.
# If you have other directories or files that will need to be added to # If you have other directories or files that will need to be added to
+16
View File
@@ -176,3 +176,19 @@ Executes a function on the clients of a specified list of players. The function
- **parameters...** the parameters that should be passed to the called function. Pass the parameters in comma separated, as you would do for a regular function call. - **parameters...** the parameters that should be passed to the called function. Pass the parameters in comma separated, as you would do for a regular function call.
**Return value**: The promise returned by this function will resolve as soon as the request for execution has been sent to the specified clients and *will not* wait until those clients have finished processing that function. The promise will not yield any return value. **Return value**: The promise returned by this function will resolve as soon as the request for execution has been sent to the specified clients and *will not* wait until those clients have finished processing that function. The promise will not yield any return value.
## Your Module Manifest
Socketlib can be set to be required by your module by including the following in your manifest:
```json
"relationships": {
"requires": [
{
"id": "socketlib",
"type": "module",
"manifest": "https://github.com/farling42/foundryvtt-socketlib/releases/latest/download/module.json"
}
]
}
```
+2 -2
View File
@@ -27,8 +27,8 @@
"esmodules": [ "esmodules": [
"src/socketlib.js" "src/socketlib.js"
], ],
"url": "#{URL}#", "url": "https://github.com/farling42/foundryvtt-socketlib",
"download": "#{DOWNLOAD}#", "download": "#{URL}#",
"manifest": "#{MANIFEST}#", "manifest": "#{MANIFEST}#",
"readme": "https://github.com/farling42/foundryvtt-socketlib/blob/master/README.md", "readme": "https://github.com/farling42/foundryvtt-socketlib/blob/master/README.md",
"changelog": "https://github.com/farling42/foundryvtt-socketlib/blob/master/CHANGELOG.md", "changelog": "https://github.com/farling42/foundryvtt-socketlib/blob/master/CHANGELOG.md",