diff options
author | Michael Ellerman <mpe@ellerman.id.au> | 2019-08-27 16:13:13 +1000 |
---|---|---|
committer | Daniel Axtens <dja@axtens.net> | 2019-08-30 17:39:06 +1000 |
commit | f94bb4eb3693d581c0658eba6ab4aa7723eca955 (patch) | |
tree | 22dae6af1ae2ca8da03898ddf9dc98a853efac30 /patchwork/migrations | |
parent | dde885c6c2f5e03388630320bc03a4cbe1040c64 (diff) | |
download | patchwork-f94bb4eb3693d581c0658eba6ab4aa7723eca955.tar patchwork-f94bb4eb3693d581c0658eba6ab4aa7723eca955.tar.gz |
models: Add commit_url_format to Project
Add a new field to Project, commit_url_format, which specifies a
format string that can be used to generate a link to a particular
commit for a project.
This is used in the display of a patch, to render the patch's commit
as a clickable link back to the commit on the SCM website.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Daniel Axtens <dja@axtens.net>
Diffstat (limited to 'patchwork/migrations')
-rw-r--r-- | patchwork/migrations/0036_project_commit_url_format.py | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/patchwork/migrations/0036_project_commit_url_format.py b/patchwork/migrations/0036_project_commit_url_format.py new file mode 100644 index 0000000..ab296d2 --- /dev/null +++ b/patchwork/migrations/0036_project_commit_url_format.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.22 on 2019-08-23 17:16 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('patchwork', '0035_project_list_archive_url_format'), + ] + + operations = [ + migrations.AddField( + model_name='project', + name='commit_url_format', + field=models.CharField(blank=True, help_text=b'URL format for a particular commit. {} will be replaced by the commit SHA.', max_length=2000), + ), + ] |