mirror of
https://github.com/YunoHost/apps.git
synced 2024-09-03 20:06:07 +02:00
Merge pull request #1823 from OniriCorpe/explicit-wishlist-message
Store: Explicit wishlist PR message
This commit is contained in:
commit
0387d84e6f
2 changed files with 8 additions and 6 deletions
12
store/app.py
12
store/app.py
|
@ -291,9 +291,7 @@ def add_to_wishlist():
|
||||||
new_branch = f"add-to-wishlist-{slug}"
|
new_branch = f"add-to-wishlist-{slug}"
|
||||||
try:
|
try:
|
||||||
# Get the commit base for the new branch, and create it
|
# Get the commit base for the new branch, and create it
|
||||||
commit_sha = repo.get_branch(
|
commit_sha = repo.get_branch(repo.default_branch).commit.sha
|
||||||
repo.default_branch
|
|
||||||
).commit.sha
|
|
||||||
repo.create_git_ref(ref=f"refs/heads/{new_branch}", sha=commit_sha)
|
repo.create_git_ref(ref=f"refs/heads/{new_branch}", sha=commit_sha)
|
||||||
except exception as e:
|
except exception as e:
|
||||||
print("... Failed to create branch ?")
|
print("... Failed to create branch ?")
|
||||||
|
@ -328,6 +326,10 @@ def add_to_wishlist():
|
||||||
|
|
||||||
Proposed by **{session['user']['username']}**
|
Proposed by **{session['user']['username']}**
|
||||||
|
|
||||||
|
Website: {website}
|
||||||
|
Upstream repo: {upstream}
|
||||||
|
Description: {description}
|
||||||
|
|
||||||
- [ ] Confirm app is self-hostable and generally makes sense to possibly integrate in YunoHost
|
- [ ] Confirm app is self-hostable and generally makes sense to possibly integrate in YunoHost
|
||||||
- [ ] Confirm app's license is opensource/free software (or not-totally-free, case by case TBD)
|
- [ ] Confirm app's license is opensource/free software (or not-totally-free, case by case TBD)
|
||||||
- [ ] Description describes concisely what the app is/does
|
- [ ] Description describes concisely what the app is/does
|
||||||
|
@ -344,7 +346,7 @@ Proposed by **{session['user']['username']}**
|
||||||
url = f"https://github.com/YunoHost/apps/pull/{pr.number}"
|
url = f"https://github.com/YunoHost/apps/pull/{pr.number}"
|
||||||
|
|
||||||
successmsg = _(
|
successmsg = _(
|
||||||
"Your proposed app has succesfully been submitted. It must now be validated by the YunoHost team. You can track progress here: %(url)s",
|
"Your proposed app has succesfully been submitted. It must now be validated by the YunoHost team. You can track progress here: <a href='%(url)s'>%(url)s</a>",
|
||||||
url=url,
|
url=url,
|
||||||
)
|
)
|
||||||
return render_template(
|
return render_template(
|
||||||
|
@ -355,7 +357,7 @@ Proposed by **{session['user']['username']}**
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
letters = string.ascii_lowercase + string.digits
|
letters = string.ascii_lowercase + string.digits
|
||||||
csrf_token = ''.join(random.choice(letters) for i in range(16))
|
csrf_token = "".join(random.choice(letters) for i in range(16))
|
||||||
session["csrf_token"] = csrf_token
|
session["csrf_token"] = csrf_token
|
||||||
return render_template(
|
return render_template(
|
||||||
"wishlist_add.html",
|
"wishlist_add.html",
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
<div role="alert" class="rounded-md border-s-4 border-green-500 bg-green-50 p-4 my-5">
|
<div role="alert" class="rounded-md border-s-4 border-green-500 bg-green-50 p-4 my-5">
|
||||||
<p class="mt-2 text-sm text-green-700 font-bold">
|
<p class="mt-2 text-sm text-green-700 font-bold">
|
||||||
<i class="fa fa-thumbs-up fa-fw" aria-hidden="true"></i>
|
<i class="fa fa-thumbs-up fa-fw" aria-hidden="true"></i>
|
||||||
{{ successmsg }}
|
{{ successmsg | safe }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
{% else %}
|
{% else %}
|
||||||
|
|
Loading…
Add table
Reference in a new issue