You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
forgejo/modules
Mario Lubenka 61db834904 Change target branch for pull request (#6488)
* Adds functionality to change target branch of created pull requests

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Use const instead of var in JavaScript additions

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Check if branches are equal and if PR already exists before changing target branch

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Make sure to check all commits

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Print error messages for user as error flash message

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Disallow changing target branch of closed or merged pull requests

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Resolve conflicts after merge of upstream/master

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Change order of branch select fields

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Removes duplicate check

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Use ctx.Tr for translations

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Recompile JS

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Use correct translation namespace

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Remove redundant if condition

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Moves most change branch logic into pull service

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Completes comment

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Add Ref to ChangesPayload for logging changed target branches
instead of creating a new struct

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Revert changes to go.mod

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Directly use createComment method

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Return 404 if pull request is not found. Move written check up

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Remove variable declaration

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Return client errors on change pull request target errors

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Return error in commit.HasPreviousCommit

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Adds blank line

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Test patch before persisting new target branch

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Update patch before testing (not working)

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Removes patch calls when changeing pull request target

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Removes unneeded check for base name

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Moves ChangeTargetBranch completely to pull service. Update patch status.

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Set webhook mode after errors were validated

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Update PR in one transaction

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Move logic for check if head is equal with branch to pull model

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Adds missing comment and simplify return

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Adjust CreateComment method call

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>
5 years ago
..
auth Branch protection: Possibility to not use whitelist but allow anyone with write access (#9055) 5 years ago
avatar Improve handling of non-square avatars (#7025) 5 years ago
base Use gitea forked macaron (#7933) 5 years ago
cache Use gitea forked macaron (#7933) 5 years ago
charset deps: update and fix chardet import (#9351) 5 years ago
context Add /milestones endpoint (#8733) 5 years ago
convert [Bug] [API] Add language to user api (#9215) 5 years ago
cron Graceful: Xorm, RepoIndexer, Cron and Others (#9282) 5 years ago
generate Integrate OAuth2 Provider (#5378) 5 years ago
git Change target branch for pull request (#6488) 5 years ago
gitgraph Move git graph from models to modules/graph (#9027) 5 years ago
graceful Fix missed change to GetManager() (#9361) 5 years ago
highlight Add a lot of extension to language mappings for syntax highlights (#7741) 5 years ago
httplib Add golangci (#6418) 5 years ago
indexer Graceful: Xorm, RepoIndexer, Cron and Others (#9282) 5 years ago
lfs Make repository management section handle lfs locks (#8726) 5 years ago
log Log: Ensure FLAGS=none is -1 (#9287) 5 years ago
markup Markdown: Sanitizier Configuration (#9075) 5 years ago
metrics Prometheus endpoint (#5256) 6 years ago
migrations Graceful: Xorm, RepoIndexer, Cron and Others (#9282) 5 years ago
notification Change target branch for pull request (#6488) 5 years ago
options Use gitea forked macaron (#7933) 5 years ago
password Add password requirement info on error (#9074) 5 years ago
pprof Add golangci (#6418) 5 years ago
private Allow Protected Branches to Whitelist Deploy Keys (#8483) 5 years ago
process Graceful: Cancel Process on monitor pages & HammerTime (#9213) 5 years ago
public Use gitea forked macaron (#7933) 5 years ago
recaptcha fixed reCAPTCHA URL (#9083) 5 years ago
references Alternate syntax for cross references (#9116) 5 years ago
repofiles Refactor comment (#9330) 5 years ago
repository Move some repository methods from models to modules/repository (#9353) 5 years ago
search Move modules/indexer to modules/indexer/code (#9301) 5 years ago
secret Integrate OAuth2 Provider (#5378) 5 years ago
session Use gitea forked macaron (#7933) 5 years ago
setting Add /milestones endpoint (#8733) 5 years ago
ssh Graceful: Xorm, RepoIndexer, Cron and Others (#9282) 5 years ago
structs Change target branch for pull request (#6488) 5 years ago
sync Graceful: Xorm, RepoIndexer, Cron and Others (#9282) 5 years ago
task Fix bug when migrate from API (#8631) 5 years ago
templates Add USE_SERVICE_WORKER setting (#9110) 5 years ago
test Add Close() method to gogitRepository (#8901) 5 years ago
timeutil Use gitea forked macaron (#7933) 5 years ago
upload Fix upload file type check (#7890) 5 years ago
user Add golangci (#6418) 5 years ago
util Convert EOL to UNIX-style to render MD properly (#8925) 5 years ago
validation Implement webhook branch filter (#7791) 5 years ago
webhook Graceful: Xorm, RepoIndexer, Cron and Others (#9282) 5 years ago