Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to change forge status messages #900

Merged
merged 11 commits into from
May 12, 2022
Merged

Conversation

qwerty287
Copy link
Contributor

@qwerty287 qwerty287 commented May 4, 2022

Allow to change the status message via template option

Closes #855

@confusedsushi
Copy link

I like the current context text. From a programmers point of view it is short, informative and probably easy to parse.

I see that someone maybe wants a more human friendly text. What about making the format string which builds the text configurable?

server/remote/common/status.go Outdated Show resolved Hide resolved
@6543 6543 added the breaking will break existing installations if no manual action happens label May 5, 2022
@6543
Copy link
Member

6543 commented May 5, 2022

I like the current context text. From a programmers point of view it is short, informative and probably easy to parse.

I see that someone maybe wants a more human friendly text. What about making the format string which builds the text configurable?

thats why it did not got my lgmt jet ... I'm also fine as is now - but I see that some like to have a more nicer looking one
I'll do two things:

  1. check if it can be done otherwise (is there a description field etc ...)
  2. if you can achive this change by config

@qwerty287
Copy link
Contributor Author

If you all think the current way is fine I'm going to close it. For me, the current way is fine too, even if it is not the best I can see.

@qwerty287 qwerty287 closed this May 5, 2022
@6543
Copy link
Member

6543 commented May 5, 2022

well just let it ope until we could run down the 2 points :)

@6543 6543 reopened this May 5, 2022
@6543 6543 added the ux user experience label May 5, 2022
@qwerty287
Copy link
Contributor Author

The new commit allows you to set a completely different status message. It uses a simple template system, you can configure it e.g. with %context to add woodpecker's context. See the added docs for more fields.

@codecov-commenter
Copy link

codecov-commenter commented May 11, 2022

Codecov Report

Merging #900 (5dca4b3) into master (acbcc53) will increase coverage by 0.32%.
The diff coverage is 100.00%.

❗ Current head 5dca4b3 differs from pull request most recent head c4446a2. Consider uploading reports for the commit c4446a2 to get more accurate results

@@            Coverage Diff             @@
##           master     #900      +/-   ##
==========================================
+ Coverage   51.58%   51.91%   +0.32%     
==========================================
  Files          80       80              
  Lines        6066     6068       +2     
==========================================
+ Hits         3129     3150      +21     
+ Misses       2758     2739      -19     
  Partials      179      179              
Impacted Files Coverage Δ
server/remote/common/status.go 41.02% <100.00%> (+41.02%) ⬆️
server/logging/log.go 54.65% <0.00%> (+5.81%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update acbcc53...c4446a2. Read the comment docs.

@qwerty287 qwerty287 changed the title Use a more user-friendly status context Allow to change SCM status messages May 11, 2022
cmd/server/flags.go Outdated Show resolved Hide resolved
@6543 6543 added enhancement improve existing features and removed breaking will break existing installations if no manual action happens labels May 11, 2022
@6543 6543 added this to the 1.0.0 milestone May 11, 2022
@woodpecker-bot
Copy link
Collaborator

woodpecker-bot commented May 11, 2022

Deployment of preview was successful: https://woodpecker-ci-woodpecker-pr-900.surge.sh

@6543
Copy link
Member

6543 commented May 11, 2022

adding tests is always a good idea ;)

@6543 6543 enabled auto-merge (squash) May 11, 2022 16:10
docs/docs/30-administration/10-server-config.md Outdated Show resolved Hide resolved
server/remote/common/status.go Outdated Show resolved Hide resolved
@6543 6543 changed the title Allow to change SCM status messages Allow to change Forge status messages May 11, 2022
@6543 6543 disabled auto-merge May 11, 2022 16:45
@qwerty287 qwerty287 changed the title Allow to change Forge status messages Allow to change forge status messages May 12, 2022
@6543
Copy link
Member

6543 commented May 12, 2022

please update the unittests too https://ci.woodpecker-ci.org/woodpecker-ci/woodpecker/build/2472/31

@6543 6543 enabled auto-merge (squash) May 12, 2022 16:47
@6543 6543 merged commit 6568751 into woodpecker-ci:master May 12, 2022
@qwerty287 qwerty287 deleted the status-ctx branch May 12, 2022 17:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement improve existing features ux user experience
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Context of commit statuses is not really "nice"
7 participants