Skip to content

Commit

Permalink
Merge branch 'release/1.1.0-alpha.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
nekofar committed Feb 22, 2024
2 parents f9a4895 + c8f5860 commit e8cc395
Show file tree
Hide file tree
Showing 9 changed files with 336 additions and 243 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
ref: ${{ github.event.release.tag_name }}

- name: Install pnpm package manager
uses: pnpm/action-setup@v2.4.0
uses: pnpm/action-setup@v3.0.0
with:
version: latest

Expand Down
44 changes: 44 additions & 0 deletions .github/workflows/git-flow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Name of the workflow
name: Git Flow

# Defines the event that triggers the workflow
on:
push:
branches:
- 'feature/*' # Trigger for pushes to feature branches
- 'bugfix/*' # Trigger for pushes to bugfix branches
- 'release/*' # Trigger for pushes to release branches
- 'hotfix/*' # Trigger for pushes to hotfix branches

# Jobs are a set of steps that execute on the same runner
jobs:
create-pull-request:
# Specifies the runner environment, using the latest Ubuntu
runs-on: ubuntu-latest
name: Create Pull Request
permissions: write-all

# Steps are individual tasks that run commands in a job
steps:
# Checks out the repository code under $GITHUB_WORKSPACE, so the job can access it
- name: Checkout Repository Code
uses: actions/[email protected]

# This step uses the Git Flow Action to create PRs based on branch types
- name: Execute Git Flow Action
uses: nekofar/git-flow-action@develop # Specifies the Git Flow Action to use and the branch
with:
# The GitHub Token for authentication with GitHub API
github-token: ${{ secrets.GITHUB_TOKEN }}
# The branch to target for release and hotfix PRs
master-branch: 'master'
# The branch to target for feature and bugfix PRs
develop-branch: 'develop'
# Prefix for feature branches
feature-prefix: 'feature/'
# Prefix for bugfix branches
bugfix-prefix: 'bugfix/'
# Prefix for release branches
release-prefix: 'release/'
# Prefix for hotfix branches
hotfix-prefix: 'hotfix/'
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,20 @@

All notable changes to this project will be documented in this file.

## [1.1.0-alpha.1]] - 2024-02-22

### Features

- Add UTM parameters to the final URLs

### Bug Fixes

- Update post url for Farcaster frames

### Miscellaneous Tasks

- Add new git flow workflow for handling pull requests

## [1.1.0-alpha.0] - 2024-01-30

### Features
Expand Down
23 changes: 20 additions & 3 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "lilnouns-click"
version = "1.1.0-alpha.0"
version = "1.1.0-alpha.1"
authors = ["Milad Nekofar <[email protected]>"]
edition = "2021"
description = "A Nounish URL shortener for LilNouns DAO."
Expand All @@ -22,7 +22,7 @@ html-minifier = { version = "5.0.0", default-features = false }
log = { version = "0.4.20", features = [] }
percent-encoding = "2.3.1"
regex = "1.10.3"
reqwest = "0.11.23"
reqwest = "0.11.24"
serde = { version = "1.0.196", features = ["derive"] }
sqids = "0.3.0"
unidecode = "0.3.0"
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
"dev": "wrangler dev"
},
"devDependencies": {
"wrangler": "3.25.0"
"wrangler": "3.28.2"
}
}
61 changes: 33 additions & 28 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 12 additions & 10 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,17 @@ mod utils;

#[event(fetch)]
async fn main(req: Request, env: Env, _ctx: Context) -> Result<Response> {
let router = Router::new();
let router = Router::new();

router
.get("/", |_, _| {
Response::redirect(Url::parse("https://lilnouns.wtf")?)
})
.get_async("/:sqid", routes::handle_redirect)
.get_async("/:sqid/og.png", routes::handle_og_image)
.post_async("/", routes::handle_creation)
.run(req, env)
.await
router
.get("/", |_, _| {
Response::redirect(Url::parse(
"https://lilnouns.wtf?utm_source=farcaster&utm_medium=social",
)?)
})
.get_async("/:sqid", routes::handle_redirect)
.get_async("/:sqid/og.png", routes::handle_og_image)
.post_async("/", routes::handle_creation)
.run(req, env)
.await
}
Loading

0 comments on commit e8cc395

Please sign in to comment.