diff --git a/src/app.py b/src/app.py index 99dd9c7..6a51841 100644 --- a/src/app.py +++ b/src/app.py @@ -82,7 +82,7 @@ def info(repo: Repository): commit_hash = log[1].split()[0][1:] try: commit_msg, commit_author, commit_url = repo.get_commit_info(commit_hash) - formatted_commit_info = f"#{commit_hash}: {commit_msg} (by {commit_author})" + formatted_commit_info = f"#{commit_hash}: {commit_msg} (by {commit_author})" except Exception as e: formatted_commit_info = '' else: diff --git a/src/repository.py b/src/repository.py index 1fa3a80..565ee6c 100644 --- a/src/repository.py +++ b/src/repository.py @@ -121,13 +121,13 @@ def _runJob(self, reponame, user): repo = self._updateRepo(reponame) try: if self._build(reponame): - msg = f"#{repo.head.commit.hexsha[:10]} Build succeeded." + msg = f"#{repo.head.commit.hexsha[:8]} Build succeeded." time_end = time.time() else: - msg = f"#{repo.head.commit.hexsha[0:10]} Build failed." + msg = f"#{repo.head.commit.hexsha[0:8]} Build failed." time_end = time.time() except: - msg = f"#{repo.head.commit.hexsha[0:10]} Build error." + msg = f"#{repo.head.commit.hexsha[0:8]} Build error." raise except GitCommandError as e: msg = f"Pull error. ({e})" @@ -250,7 +250,7 @@ def get_current_build_status(self): return { "status": status, "timeinfo": f"- {self._format_time_ago(last_record[0])}", - "commit": f" - #{commit_hash}: {commit_msg} (by {commit_author})" + "commit": f" - #{commit_hash}: {commit_msg} (by {commit_author})" } except Exception as e: return { diff --git a/src/static/favicon.ico b/src/static/favicon.ico new file mode 100644 index 0000000..c4a3e87 Binary files /dev/null and b/src/static/favicon.ico differ diff --git a/src/static/style.css b/src/static/style.css index d655422..e287724 100644 --- a/src/static/style.css +++ b/src/static/style.css @@ -1,3 +1,47 @@ table td { padding: 1px 10px 1px 10px; +} + +:root { + --bs-pink: #da1175; +} + +.btn-pink { + color: #fff; + background-color: var(--bs-pink); + border-color: var(--bs-pink); +} + +.btn-pink:hover { + color: #fff; + background-color: #b80e63; + border-color: #ad0d5d; +} + +.btn-outline-pink { + color: var(--bs-pink) !important; + border-color: var(--bs-pink) !important; +} + +.btn-outline-pink:hover { + color: #fff !important; + background-color: var(--bs-pink) !important; + border-color: var(--bs-pink) !important; +} + +.link-pink { + color: var(--bs-pink) !important; +} + +.link-pink:hover { + color: #b80e63 !important; + text-decoration: underline !important; +} + +.text-pink { + color: var(--bs-pink) !important; +} + +.bg-pink { + background-color: var(--bs-pink) !important; } \ No newline at end of file diff --git a/src/templates/base.html.jinja b/src/templates/base.html.jinja index 6a0335f..1d95424 100644 --- a/src/templates/base.html.jinja +++ b/src/templates/base.html.jinja @@ -5,14 +5,14 @@ Astrid - {% block title %}{% endblock %} + - -