Skip to content

Commit

Permalink
Merge pull request #57 from near/june27_updates
Browse files Browse the repository at this point in the history
chore: add press, page, and categories with url fixes
  • Loading branch information
charleslavon authored Jun 28, 2024
2 parents c536c4b + 2248e91 commit bf4cb3b
Show file tree
Hide file tree
Showing 652 changed files with 8,118 additions and 8,087 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/fix_paths.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
on:
push:
branches: [develop]
permissions:
contents: write

jobs:
fix-paths:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: script
shell: bash
run: ./bin/replace_all.sh

- name: Check the diff
id: check_diff
run: |
git diff --quiet . || echo "changed=true" >> $GITHUB_OUTPUT
- name: Log next steps
if: steps.check_diff.outputs.changed != 'true'
run: |
echo "Workflow detected that no changes are needed."
- name: create pull request
if: steps.check_diff.outputs.changed == 'true'
run: gh pr create -B base_branch -H branch_to_merge -m 'auto-update URL paths in response to marketing content update'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
38 changes: 0 additions & 38 deletions .github/workflows/update_submodules.yml

This file was deleted.

7 changes: 7 additions & 0 deletions bin/replace_all.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash

./bin/search_and_replace.sh public\/blog "\/wp\-content" "https\:\/\/pages\.near\.org\/wp\-content"
./bin/search_and_replace.sh public\/blog "\=\"\/wp\-content" "\=\"https\:\/\/pages\.near\.org\/wp-content"
./bin/search_and_replace.sh public\/blog "\/wp\-includes" "https\:\/\/pages\.near\.org\/wp\-includes"
./bin/search_and_replace.sh public\/blog "\?paged\=" "page\/"
./bin/search_and_replace.sh public\/blog\/near-foundation-announces-policy-principles "\=https\:\/\/s3\-eu\-west\-2\.amazonaws\.com\/lawcom\-prod\-storage\-11jsxou24uy7q\/uploads\/2022\/07\/Digital\-Assets\-Consultation\-Paper\-Law\-Commission\-1\.pdf" ""
32 changes: 32 additions & 0 deletions bin/search_and_replace.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#!/bin/bash

# Check if correct number of arguments are provided
if [ "$#" -ne 3 ]; then
echo "Usage: $0 <directory> <search_string> <replacement_string>"
exit 1
fi

directory="$1"
search_string="$2"
replacement_string="$3"

# Check if directory exists
if [ ! -d "$directory" ]; then
echo "Error: Directory '$directory' not found."
exit 1
fi

# Perform search and replace recursively
echo "Searching for '$search_string' and replacing with '$replacement_string' in files under '$directory'..."

# Use find command to search for files recursively in the directory
find "$directory" -type f -print0 | while IFS= read -r -d '' file; do
# Perform the search and replace using sed
sed -i 's/'$search_string'/'$replacement_string'/g' "$file"
# Note: the above sed command works on unix/linux, but not on MacOS
# To run this script locally on a mac, comment out the above and use the line below
# sed -i '' 's/'$search_string'/'$replacement_string'/g' "$file"
echo "Modified: $file"
done

echo "Search and replace complete."
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<generator>https://wordpress.org/?v=6.5.3</generator>

<image>
<url>/wp-content/uploads/2020/09/cropped-favicon-32x32.png</url>
<url>https://pages.near.org/wp-content/uploads/2020/09/cropped-favicon-32x32.png</url>
<title>A Post from Illia Polosukhin Archives &#8211; NEAR Protocol</title>
<link>/blog/category/a-post-from-illia-polosukhin/</link>
<width>32</width>
Expand Down
34 changes: 17 additions & 17 deletions public/blog/category/a-post-from-illia-polosukhin/index.html

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions public/blog/category/case-studies/feed/index.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<generator>https://wordpress.org/?v=6.5.3</generator>

<image>
<url>/wp-content/uploads/2020/09/cropped-favicon-32x32.png</url>
<url>https://pages.near.org/wp-content/uploads/2020/09/cropped-favicon-32x32.png</url>
<title>Case Studies Archives &#8211; NEAR Protocol</title>
<link>/blog/category/case-studies/</link>
<width>32</width>
Expand Down Expand Up @@ -333,7 +333,7 @@
<figure class="wp-block-image size-large"><img fetchpriority="high" decoding="async" width="1024" height="576" src="/wp-content/uploads/2024/06/cosmose-diagram-1024x576.png" alt="" class="wp-image-21400" srcset="/wp-content/uploads/2024/06/cosmose-diagram-1024x576.png 1024w, /wp-content/uploads/2024/06/cosmose-diagram-300x169.png 300w, /wp-content/uploads/2024/06/cosmose-diagram-768x432.png 768w, /wp-content/uploads/2024/06/cosmose-diagram-1536x864.png 1536w, /wp-content/uploads/2024/06/cosmose-diagram.png 1920w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>
<figure class="wp-block-image size-large"><img fetchpriority="high" decoding="async" width="1024" height="576" src="https://pages.near.org/wp-content/uploads/2024/06/cosmose-diagram-1024x576.png" alt="" class="wp-image-21400" srcset="https://pages.near.org/wp-content/uploads/2024/06/cosmose-diagram-1024x576.png 1024w, https://pages.near.org/wp-content/uploads/2024/06/cosmose-diagram-300x169.png 300w, https://pages.near.org/wp-content/uploads/2024/06/cosmose-diagram-768x432.png 768w, https://pages.near.org/wp-content/uploads/2024/06/cosmose-diagram-1536x864.png 1536w, https://pages.near.org/wp-content/uploads/2024/06/cosmose-diagram.png 1920w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>
Expand Down Expand Up @@ -759,7 +759,7 @@
<content:encoded><![CDATA[<p><span style="font-weight: 400;">The </span><a href="https://nft.hiphop/"><span style="font-weight: 400;">NFT.HipHop</span></a><span style="font-weight: 400;"> marketplace auction of the Hip Hop Heads collection began on Juneteenth and will run for 37 days, until July 25. A celebration of the history of hip hop and its most iconic artists, the pop-up marketplace also highlights some engineering innovations that highlight the advanced NFT developer and user experience on NEAR. NFT.HipHop incorporates seamless NEAR account creation, the ability to purchase NFTs with a credit card, customizable royalty splits that follow NFTs across marketplaces, and the debut of NFTs displaying in the NEAR wallet. </span></p>
<h3>Inside the User Experience</h3>
<p><span style="font-weight: 400;">The NFT.HipHop auction marks a radical change in the way that NFT marketplaces can be executed. The user onboarding flow makes the process universally accessible and as familiar as any Web2 purchasing experience. With this new creative approach, end users with no existing crypto knowledge can easily purchase NFTs without the hurdles of onboarding to an exchange, purchasing cryptocurrency, or choosing and connecting a wallet. Thanks to the app’s wallet faucet and NEAR’s human-rea</span>dable account naming system, all a user has to do is choose a NEAR name and the application handles the rest.</p>
<p><img loading="lazy" decoding="async" class="aligncenter size-full wp-image-12737" src="/wp-content/uploads/2021/07/inside-nfthiphop-ux.png" alt="" width="1400" height="520" srcset="/wp-content/uploads/2021/07/inside-nfthiphop-ux.png 1400w, /wp-content/uploads/2021/07/inside-nfthiphop-ux-300x111.png 300w, /wp-content/uploads/2021/07/inside-nfthiphop-ux-1024x380.png 1024w, /wp-content/uploads/2021/07/inside-nfthiphop-ux-768x285.png 768w" sizes="(max-width: 1400px) 100vw, 1400px" /></p>
<p><img loading="lazy" decoding="async" class="aligncenter size-full wp-image-12737" src="https://pages.near.org/wp-content/uploads/2021/07/inside-nfthiphop-ux.png" alt="" width="1400" height="520" srcset="https://pages.near.org/wp-content/uploads/2021/07/inside-nfthiphop-ux.png 1400w, https://pages.near.org/wp-content/uploads/2021/07/inside-nfthiphop-ux-300x111.png 300w, https://pages.near.org/wp-content/uploads/2021/07/inside-nfthiphop-ux-1024x380.png 1024w, https://pages.near.org/wp-content/uploads/2021/07/inside-nfthiphop-ux-768x285.png 768w" sizes="(max-width: 1400px) 100vw, 1400px" /></p>
<p><span style="font-weight: 400;">Marketplace credits for placing NFT bids can be purchased with a credit card. There is no complex, multi-step process of purchasing crypto through an exchan</span>ge and paying high transaction fees as would be required with other NFT marketplaces today. Using crypto can be a confusing process for a novice, but by employing this progressive onboarding flow, the barrier to entry for crypto has been all but eliminated. The goal is to make NFTs accessible to all kinds of hip hop fans, not just crypto-native fans.</p>
<h3>Inside the App</h3>
<p><span style="font-weight: 400;">At its core, the NFT.HipHop marketplace is a standard React application with state management. dApp developers retrieve on-chain state using the NEAR API Helper, which interacts with the NEAR blockchain via CloudFlare. This tool allows caching heavy queries when the user lands on the page, as there are 103 portraits in the Hip Hop Heads collection and 37 available editions of each Head. As the user explores the marketplace, they’re only viewing one basic type of NFT. The canonical tokens, or “gem tokens,” are stored, and individual edition bids and sales are visible to the user within each gem. When clicking on an individual token, one sees which editions are for sale and the bidding history is pulled from the marketplace contract.</span></p>
Expand Down
46 changes: 23 additions & 23 deletions public/blog/category/case-studies/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/case-studies/page/2/index.html

Large diffs are not rendered by default.

42 changes: 21 additions & 21 deletions public/blog/category/case-studies/page/3/index.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions public/blog/category/community/feed/index.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<generator>https://wordpress.org/?v=6.5.3</generator>

<image>
<url>/wp-content/uploads/2020/09/cropped-favicon-32x32.png</url>
<url>https://pages.near.org/wp-content/uploads/2020/09/cropped-favicon-32x32.png</url>
<title>Community Archives &#8211; NEAR Protocol</title>
<link>/blog/category/community/</link>
<width>32</width>
Expand Down Expand Up @@ -927,7 +927,7 @@
<figure class="wp-block-image"><img fetchpriority="high" decoding="async" width="1600" height="1200" src="/wp-content/uploads/2024/04/image.jpeg" alt="" class="wp-image-21317" srcset="/wp-content/uploads/2024/04/image.jpeg 1600w, /wp-content/uploads/2024/04/image-300x225.jpeg 300w, /wp-content/uploads/2024/04/image-1024x768.jpeg 1024w, /wp-content/uploads/2024/04/image-768x576.jpeg 768w, /wp-content/uploads/2024/04/image-1536x1152.jpeg 1536w" sizes="(max-width: 1600px) 100vw, 1600px" /></figure>
<figure class="wp-block-image"><img fetchpriority="high" decoding="async" width="1600" height="1200" src="https://pages.near.org/wp-content/uploads/2024/04/image.jpeg" alt="" class="wp-image-21317" srcset="https://pages.near.org/wp-content/uploads/2024/04/image.jpeg 1600w, https://pages.near.org/wp-content/uploads/2024/04/image-300x225.jpeg 300w, https://pages.near.org/wp-content/uploads/2024/04/image-1024x768.jpeg 1024w, https://pages.near.org/wp-content/uploads/2024/04/image-768x576.jpeg 768w, https://pages.near.org/wp-content/uploads/2024/04/image-1536x1152.jpeg 1536w" sizes="(max-width: 1600px) 100vw, 1600px" /></figure>
Expand Down
46 changes: 23 additions & 23 deletions public/blog/category/community/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/10/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/11/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/12/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/13/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/14/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/15/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/16/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/17/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/18/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/19/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/2/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/20/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/21/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/22/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/23/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/24/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/25/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/26/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/27/index.html

Large diffs are not rendered by default.

30 changes: 15 additions & 15 deletions public/blog/category/community/page/28/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/3/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/4/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/5/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/6/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/7/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/8/index.html

Large diffs are not rendered by default.

46 changes: 23 additions & 23 deletions public/blog/category/community/page/9/index.html

Large diffs are not rendered by default.

Loading

0 comments on commit bf4cb3b

Please sign in to comment.