Skip to content

Commit

Permalink
Merge pull request #80 from contentstack/fix/DX-574
Browse files Browse the repository at this point in the history
fix: added workflow for maven publish
  • Loading branch information
reeshika-h authored Oct 3, 2024
2 parents b5dee71 + e4f8c1d commit c743d1b
Show file tree
Hide file tree
Showing 9 changed files with 71 additions and 54 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/maven-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,23 @@ jobs:
server-id: github
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
gpg-passphrase: ${{ secrets.GPG_PASSPHRASE }}
- name: Set up Maven settings for OSSRH
run: |
mkdir -p $HOME/.m2
echo "<settings>
<servers>
<server>
<id>ossrh</id>
<username>${{ secrets.OSSRH_USERNAME }}</username>
<password>${{ secrets.OSSRH_PASSWORD }}</password>
</server>
<server>
<id>github</id>
<username>${{ github.actor }}</username>
<password>${{ secrets.GITHUB_TOKEN }}</password>
</server>
</servers>
</settings>" > $HOME/.m2/settings.xml
- name: Publish to GitHub Packages
run: mvn --batch-mode -Dgpg.passphrase=${{ secrets.GPG_PASSPHRASE }} deploy
env:
Expand Down
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.contentstack.sdk</groupId>
<artifactId>utils</artifactId>
<version>1.2.11</version>
<version>1.2.15</version>
<packaging>jar</packaging>
<name>Contentstack-utils</name>
<description>Java Utils SDK for Contentstack Content Delivery API, Contentstack is a headless CMS</description>
Expand All @@ -28,7 +28,7 @@
<maven-release-plugin.version>2.5.3</maven-release-plugin.version>
<validation-version>2.0.1.Final</validation-version>
<json-version>20240303</json-version>
<spring-web-version>6.1.6</spring-web-version>
<spring-web-version>6.1.12</spring-web-version>
<org.apache.commons-text>1.12.0</org.apache.commons-text>
</properties>

Expand Down
12 changes: 6 additions & 6 deletions src/test/resources/file.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"display-type": "display",
"asset-uid": "blt51f558a28ef555ca",
"content-type-uid": "sys_assets",
"asset-link": "https://images.contentstack.io/v3/assets/blt6fc934a068135ff9/blt51f558a28ef555ca/6643371882c344cb839ec1a8/ben.jpeg",
"asset-link": "https://images.contentstack.io/v3/assets/***REMOVED***/blt51f558a28ef555ca/6643371882c344cb839ec1a8/ben.jpeg",
"asset-name": "Designer.png",
"asset-type": "image/jpeg",
"type": "asset",
Expand Down Expand Up @@ -47,7 +47,7 @@
{
"node": {
"title": "Designer.png",
"url": "https://images.contentstack.io/v3/assets/blt6fc934a068135ff9/blt51f558a28ef555ca/66545ff10258be81fc639ae5/Virginia_Woolf_Headshot.jpg",
"url": "https://images.contentstack.io/v3/assets/***REMOVED***/blt51f558a28ef555ca/66545ff10258be81fc639ae5/Virginia_Woolf_Headshot.jpg",
"system": {
"uid": "blt51f558a28ef555ca",
"content_type_uid": "sys_assets"
Expand All @@ -63,7 +63,7 @@
{
"node": {
"title": "W._E._B._Du_Bois_Headshot.jpg",
"url": "https://images.contentstack.io/v3/assets/blt6fc934a068135ff9/blt897c06ebf8c6353a/66545fe479abeeb60a3d4e35/Mark_Twain_Headshot.jpg",
"url": "https://images.contentstack.io/v3/assets/***REMOVED***/blt897c06ebf8c6353a/66545fe479abeeb60a3d4e35/Mark_Twain_Headshot.jpg",
"system": {
"content_type_uid": "sys_assets",
"uid": "blt897c06ebf8c6353a"
Expand All @@ -73,7 +73,7 @@
{
"node": {
"title": "iot-icon.png",
"url": "https://images.contentstack.io/v3/assets/blt6fc934a068135ff9/bltbd81ff2ed42f1317/6654501e466a1c9b3edecb21/iot-icon.png",
"url": "https://images.contentstack.io/v3/assets/***REMOVED***/bltbd81ff2ed42f1317/6654501e466a1c9b3edecb21/iot-icon.png",
"system": {
"content_type_uid": "sys_assets",
"uid": "bltbd81ff2ed42f1317"
Expand All @@ -94,7 +94,7 @@
"display-type": "display",
"asset-uid": "blt897c06ebf8c6353a",
"content-type-uid": "sys_assets",
"asset-link": "https://images.contentstack.io/v3/assets/blt6fc934a068135ff9/blt897c06ebf8c6353a/6644340e015b1c2d2b56ca48/W._E._B._Du_Bois_Headshot.jpg",
"asset-link": "https://images.contentstack.io/v3/assets/***REMOVED***/blt897c06ebf8c6353a/6644340e015b1c2d2b56ca48/W._E._B._Du_Bois_Headshot.jpg",
"asset-name": "W._E._B._Du_Bois_Headshot.jpg",
"asset-type": "image/jpeg",
"type": "asset",
Expand Down Expand Up @@ -126,7 +126,7 @@
"display-type": "display",
"asset-uid": "bltbd81ff2ed42f1317",
"content-type-uid": "sys_assets",
"asset-link": "https://images.contentstack.io/v3/assets/blt6fc934a068135ff9/bltbd81ff2ed42f1317/664425e3a3f9df03dfc0e5e6/5216292.jpg",
"asset-link": "https://images.contentstack.io/v3/assets/***REMOVED***/bltbd81ff2ed42f1317/664425e3a3f9df03dfc0e5e6/5216292.jpg",
"asset-name": "iot-icon.png",
"asset-type": "image/jpeg",
"type": "asset",
Expand Down
8 changes: 4 additions & 4 deletions src/test/resources/issue/jsonfile.json
Original file line number Diff line number Diff line change
Expand Up @@ -336,12 +336,12 @@
}
],
"multi_line": "Multi line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textbox",
"rich_text_editor": "<img data-image=\"199k9jsr64s5\" src=\"https://stag-images.contentstack.io/v3/assets/77263d300aee3e6b/c9d4efe393ee4c5a/5e157cf29da2de41a1ac2ff1/220px-Bastet_Istanbul_museum.JPG\" data-sys-asset-uid=\"c9d4efe393ee4c5a\" alt=\"220px-Bastet_Istanbul_museum.JPG\">",
"rich_text_editor": "<img data-image=\"199k9jsr64s5\" src=\"***REMOVED***/v3/assets/77263d300aee3e6b/c9d4efe393ee4c5a/5e157cf29da2de41a1ac2ff1/220px-Bastet_Istanbul_museum.JPG\" data-sys-asset-uid=\"c9d4efe393ee4c5a\" alt=\"220px-Bastet_Istanbul_museum.JPG\">",
"single_line": "Single line textbox",
"suraj_123": [
{
"single_line": "Multi line textbox",
"rich_text_editor": "<img data-image=\"mzeant040dnw\" src=\"https://stag-images.contentstack.io/v3/assets/77263d300aee3e6b/863ce52b0c65d670/5e157d0d1ec50841d6bccdb4/220px-House_sparrow04.jpg\" data-sys-asset-uid=\"863ce52b0c65d670\" alt=\"220px-House_sparrow04.jpg\">",
"rich_text_editor": "<img data-image=\"mzeant040dnw\" src=\"***REMOVED***/v3/assets/77263d300aee3e6b/863ce52b0c65d670/5e157d0d1ec50841d6bccdb4/220px-House_sparrow04.jpg\" data-sys-asset-uid=\"863ce52b0c65d670\" alt=\"220px-House_sparrow04.jpg\">",
"markdown": "Multi line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textbox",
"number": 45346346
}
Expand Down Expand Up @@ -670,12 +670,12 @@
}
],
"multi_line": "Multi line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textbox",
"rich_text_editor": "<img data-image=\"199k9jsr64s5\" src=\"https://stag-images.contentstack.io/v3/assets/77263d300aee3e6b/c9d4efe393ee4c5a/5e157cf29da2de41a1ac2ff1/220px-Bastet_Istanbul_museum.JPG\" data-sys-asset-uid=\"c9d4efe393ee4c5a\" alt=\"220px-Bastet_Istanbul_museum.JPG\">",
"rich_text_editor": "<img data-image=\"199k9jsr64s5\" src=\"***REMOVED***/v3/assets/77263d300aee3e6b/c9d4efe393ee4c5a/5e157cf29da2de41a1ac2ff1/220px-Bastet_Istanbul_museum.JPG\" data-sys-asset-uid=\"c9d4efe393ee4c5a\" alt=\"220px-Bastet_Istanbul_museum.JPG\">",
"single_line": "Single line textbox",
"suraj_123": [
{
"single_line": "Multi line textbox",
"rich_text_editor": "<img data-image=\"mzeant040dnw\" src=\"https://stag-images.contentstack.io/v3/assets/77263d300aee3e6b/863ce52b0c65d670/5e157d0d1ec50841d6bccdb4/220px-House_sparrow04.jpg\" data-sys-asset-uid=\"863ce52b0c65d670\" alt=\"220px-House_sparrow04.jpg\">",
"rich_text_editor": "<img data-image=\"mzeant040dnw\" src=\"***REMOVED***/v3/assets/77263d300aee3e6b/863ce52b0c65d670/5e157d0d1ec50841d6bccdb4/220px-House_sparrow04.jpg\" data-sys-asset-uid=\"863ce52b0c65d670\" alt=\"220px-House_sparrow04.jpg\">",
"markdown": "Multi line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textbox",
"number": 45346346
}
Expand Down
8 changes: 4 additions & 4 deletions src/test/resources/multiple_rich_text_content.json
Original file line number Diff line number Diff line change
Expand Up @@ -282,11 +282,11 @@
}
}],
"multi_line": "Multi line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textbox",
"rich_text_editor": "<img data-image=\"199k9jsr64s5\" src=\"https://stag-images.contentstack.io/v3/assets/77263d300aee3e6b/c9d4efe393ee4c5a/5e157cf29da2de41a1ac2ff1/220px-Bastet_Istanbul_museum.JPG\" data-sys-asset-uid=\"c9d4efe393ee4c5a\" alt=\"220px-Bastet_Istanbul_museum.JPG\">",
"rich_text_editor": "<img data-image=\"199k9jsr64s5\" src=\"***REMOVED***/v3/assets/77263d300aee3e6b/c9d4efe393ee4c5a/5e157cf29da2de41a1ac2ff1/220px-Bastet_Istanbul_museum.JPG\" data-sys-asset-uid=\"c9d4efe393ee4c5a\" alt=\"220px-Bastet_Istanbul_museum.JPG\">",
"single_line": "Single line textbox",
"suraj_123": [{
"single_line": "Multi line textbox",
"rich_text_editor": "<img data-image=\"mzeant040dnw\" src=\"https://stag-images.contentstack.io/v3/assets/77263d300aee3e6b/863ce52b0c65d670/5e157d0d1ec50841d6bccdb4/220px-House_sparrow04.jpg\" data-sys-asset-uid=\"863ce52b0c65d670\" alt=\"220px-House_sparrow04.jpg\">",
"rich_text_editor": "<img data-image=\"mzeant040dnw\" src=\"***REMOVED***/v3/assets/77263d300aee3e6b/863ce52b0c65d670/5e157d0d1ec50841d6bccdb4/220px-House_sparrow04.jpg\" data-sys-asset-uid=\"863ce52b0c65d670\" alt=\"220px-House_sparrow04.jpg\">",
"markdown": "Multi line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textbox",
"number": 45346346

Expand Down Expand Up @@ -586,11 +586,11 @@
}
}],
"multi_line": "Multi line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textbox",
"rich_text_editor": "<img data-image=\"199k9jsr64s5\" src=\"https://stag-images.contentstack.io/v3/assets/77263d300aee3e6b/c9d4efe393ee4c5a/5e157cf29da2de41a1ac2ff1/220px-Bastet_Istanbul_museum.JPG\" data-sys-asset-uid=\"c9d4efe393ee4c5a\" alt=\"220px-Bastet_Istanbul_museum.JPG\">",
"rich_text_editor": "<img data-image=\"199k9jsr64s5\" src=\"***REMOVED***/v3/assets/77263d300aee3e6b/c9d4efe393ee4c5a/5e157cf29da2de41a1ac2ff1/220px-Bastet_Istanbul_museum.JPG\" data-sys-asset-uid=\"c9d4efe393ee4c5a\" alt=\"220px-Bastet_Istanbul_museum.JPG\">",
"single_line": "Single line textbox",
"suraj_123": [{
"single_line": "Multi line textbox",
"rich_text_editor": "<img data-image=\"mzeant040dnw\" src=\"https://stag-images.contentstack.io/v3/assets/77263d300aee3e6b/863ce52b0c65d670/5e157d0d1ec50841d6bccdb4/220px-House_sparrow04.jpg\" data-sys-asset-uid=\"863ce52b0c65d670\" alt=\"220px-House_sparrow04.jpg\">",
"rich_text_editor": "<img data-image=\"mzeant040dnw\" src=\"***REMOVED***/v3/assets/77263d300aee3e6b/863ce52b0c65d670/5e157d0d1ec50841d6bccdb4/220px-House_sparrow04.jpg\" data-sys-asset-uid=\"863ce52b0c65d670\" alt=\"220px-House_sparrow04.jpg\">",
"markdown": "Multi line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textboxMulti line textbox",
"number": 45346346

Expand Down
4 changes: 2 additions & 2 deletions src/test/resources/reports/article2.json
Original file line number Diff line number Diff line change
Expand Up @@ -1444,7 +1444,7 @@
"display-type": "display",
"asset-uid": "blt1e8458b798a67cf5",
"content-type-uid": "sys_assets",
"asset-link": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blt1e8458b798a67cf5/650b78874f22f8000d8c82e5/couldnt_submit_shipment.png",
"asset-link": "***REMOVED***/v3/assets/***REMOVED***/blt1e8458b798a67cf5/650b78874f22f8000d8c82e5/couldnt_submit_shipment.png",
"asset-name": "couldnt_submit_shipment.png",
"asset-type": "image/png",
"type": "asset",
Expand Down Expand Up @@ -1597,7 +1597,7 @@
"file_size": "97657",
"tags": [],
"filename": "couldnt_submit_shipment.png",
"url": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blt1e8458b798a67cf5/650b78874f22f8000d8c82e5/couldnt_submit_shipment.png",
"url": "***REMOVED***/v3/assets/***REMOVED***/blt1e8458b798a67cf5/650b78874f22f8000d8c82e5/couldnt_submit_shipment.png",
"ACL": [],
"parent_uid": "blt7c541342b35c3564",
"_version": 1,
Expand Down
4 changes: 2 additions & 2 deletions src/test/resources/reports/article3.json
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@
"display-type": "display",
"asset-uid": "blt80fc6f2ccca9406a",
"content-type-uid": "sys_assets",
"asset-link": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blt80fc6f2ccca9406a/64fa50d5b979ea000d97a176/Big_and_Bulky.png",
"asset-link": "***REMOVED***/v3/assets/***REMOVED***/blt80fc6f2ccca9406a/64fa50d5b979ea000d97a176/Big_and_Bulky.png",
"asset-name": "Big_and_Bulky.png",
"asset-type": "image/png",
"type": "asset",
Expand Down Expand Up @@ -1935,7 +1935,7 @@
"file_size": "136896",
"tags": [],
"filename": "Big_and_Bulky.png",
"url": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blt80fc6f2ccca9406a/64fa50d5b979ea000d97a176/Big_and_Bulky.png",
"url": "***REMOVED***/v3/assets/***REMOVED***/blt80fc6f2ccca9406a/64fa50d5b979ea000d97a176/Big_and_Bulky.png",
"ACL": [],
"parent_uid": "blt7fdffe41992d7f16",
"_version": 1,
Expand Down
12 changes: 6 additions & 6 deletions src/test/resources/reports/article4.json
Original file line number Diff line number Diff line change
Expand Up @@ -765,7 +765,7 @@
"display-type": "display",
"asset-uid": "blt759bd3ebb372f518",
"content-type-uid": "sys_assets",
"asset-link": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blt759bd3ebb372f518/6500d116a39049000db76491/Image_1.jpeg",
"asset-link": "***REMOVED***/v3/assets/***REMOVED***/blt759bd3ebb372f518/6500d116a39049000db76491/Image_1.jpeg",
"asset-name": "Image_1.jpeg",
"asset-type": "image/jpeg",
"type": "asset",
Expand Down Expand Up @@ -867,7 +867,7 @@
"display-type": "display",
"asset-uid": "blta55d379a7c380155",
"content-type-uid": "sys_assets",
"asset-link": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blta55d379a7c380155/6500d116a39049000db7648d/Image_2.jpeg",
"asset-link": "***REMOVED***/v3/assets/***REMOVED***/blta55d379a7c380155/6500d116a39049000db7648d/Image_2.jpeg",
"asset-name": "Image_2.jpeg",
"asset-type": "image/jpeg",
"type": "asset",
Expand Down Expand Up @@ -973,7 +973,7 @@
"display-type": "display",
"asset-uid": "blt691bf4de7736a124",
"content-type-uid": "sys_assets",
"asset-link": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blt691bf4de7736a124/6500d117103154000dae6bd7/Image_3.jpeg",
"asset-link": "***REMOVED***/v3/assets/***REMOVED***/blt691bf4de7736a124/6500d117103154000dae6bd7/Image_3.jpeg",
"asset-name": "Image_3.jpeg",
"asset-type": "image/jpeg",
"type": "asset",
Expand Down Expand Up @@ -1256,7 +1256,7 @@
"file_size": "370751",
"tags": [],
"filename": "Image_1.jpeg",
"url": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blt759bd3ebb372f518/6500d116a39049000db76491/Image_1.jpeg",
"url": "***REMOVED***/v3/assets/***REMOVED***/blt759bd3ebb372f518/6500d116a39049000db76491/Image_1.jpeg",
"ACL": [],
"parent_uid": "bltecb4c7ac7cba49cf",
"_version": 1,
Expand All @@ -1282,7 +1282,7 @@
"file_size": "432469",
"tags": [],
"filename": "Image_2.jpeg",
"url": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blta55d379a7c380155/6500d116a39049000db7648d/Image_2.jpeg",
"url": "***REMOVED***/v3/assets/***REMOVED***/blta55d379a7c380155/6500d116a39049000db7648d/Image_2.jpeg",
"ACL": [],
"parent_uid": "bltecb4c7ac7cba49cf",
"_version": 1,
Expand All @@ -1308,7 +1308,7 @@
"file_size": "178058",
"tags": [],
"filename": "Image_3.jpeg",
"url": "https://azure-na-images.contentstack.com/v3/assets/blta7903c6b840b702d/blt691bf4de7736a124/6500d117103154000dae6bd7/Image_3.jpeg",
"url": "***REMOVED***/v3/assets/***REMOVED***/blt691bf4de7736a124/6500d117103154000dae6bd7/Image_3.jpeg",
"ACL": [],
"parent_uid": "bltecb4c7ac7cba49cf",
"_version": 1,
Expand Down
Loading

0 comments on commit c743d1b

Please sign in to comment.