aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKevin J Hoerr <kjhoerr@protonmail.com>2019-11-30 01:35:58 -0500
committerKevin J Hoerr <kjhoerr@protonmail.com>2019-11-30 01:35:58 -0500
commitbd041baf0f3c9af7b331becc4c982ce5e835c054 (patch)
tree3490bab19205e8c3e5225b9fc618f913d5ef19c8
parent6e9a8402c3b5901d4cf5c9b470bd8d0e90738ef7 (diff)
downloadao-coverage-bd041baf0f3c9af7b331becc4c982ce5e835c054.tar.gz
ao-coverage-bd041baf0f3c9af7b331becc4c982ce5e835c054.tar.bz2
ao-coverage-bd041baf0f3c9af7b331becc4c982ce5e835c054.zip
Prepare repository for 0.1.0 release
-rw-r--r--CHANGELOG.md22
-rw-r--r--README.md4
-rw-r--r--package.json2
-rw-r--r--public/bash6
-rw-r--r--src/index.ts6
-rw-r--r--src/metadata.ts3
6 files changed, 26 insertions, 17 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
new file mode 100644
index 0000000..9b771e2
--- /dev/null
+++ b/CHANGELOG.md
@@ -0,0 +1,22 @@
+# Changelog
+
+All notable changes to this project will be documented in this file.
+
+The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
+and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
+
+## [Unreleased]
+
+## [0.1.0]
+
+### Added
+
+- Workspace, CHANGELOG, README, LICENSE, etc.
+- `/v1/` Endpoints: POST for uploading report, GET for svg badge and report file
+- Format interfaces
+- Format specification for Tarpaulin HTML reports
+- Badge creation with color gradients green -> yellow -> red based on coverage percentage
+- Code formatting using Prettier
+
+[unreleased]: https://git.submelon.dev/kjhoerr/ao-coverage/src/branch/trunk
+[0.1.0]: https://git.submelon.dev/kjhoerr/ao-coverage/src/tag/v0.1.0
diff --git a/README.md b/README.md
index f4f0b3e..b87138d 100644
--- a/README.md
+++ b/README.md
@@ -1,3 +1,5 @@
# ao-coverage
-A simple coverage handler and server. \ No newline at end of file
+A simple coverage handler and server. The basic function provides an SVG badge with the coverage percentage and a link to the uploaded HTML coverage report. Only basic metadata is required to persist to track the latest commits for the linked branches.
+
+Currently, the only supported code coverage format is [Tarpaulin](https://crates.io/crates/cargo-tarpaulin), which is specific to Rust. Recommended formats and pull requests are welcome! If you want an account for this Gitea to interact with this repository, please contact the maintainer at [kjhoerr@submelon.tech](mailto:kjhoerr@submelon.tech).
diff --git a/package.json b/package.json
index 6ffa3f4..9699d44 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "ao-coverage",
- "version": "1.0.0",
+ "version": "0.1.0",
"description": "Simple code coverage storage and server",
"repository": {
"type": "git",
diff --git a/public/bash b/public/bash
deleted file mode 100644
index 2e0591a..0000000
--- a/public/bash
+++ /dev/null
@@ -1,6 +0,0 @@
-#!/bin/sh
-
-## AAAAAAAAAA
-
-#TODO send file via curl
-#TODO process response code \ No newline at end of file
diff --git a/src/index.ts b/src/index.ts
index e55ad10..b6f41e5 100644
--- a/src/index.ts
+++ b/src/index.ts
@@ -6,7 +6,6 @@ import path from "path";
import fs from "fs";
import formats, { Format } from "./formats";
-import metadata from "./metadata";
// Start-up configuration
dotenv.config();
@@ -26,9 +25,6 @@ if (!path.isAbsolute(HOST_DIR)) {
const app: express.Application = express();
-// serve script for posting coverage report
-app.use("/bash", express.static(path.join(__dirname, "..", "public", "bash")));
-
// Upload HTML file
app.post("/v1/:org/:repo/:branch/:commit.html", (req, res) => {
const { org, repo, branch, commit } = req.params;
@@ -97,7 +93,6 @@ app.get("/v1/:org/:repo/:branch.svg", (req, res) => {
//TODO @Metadata get the commit @@ via metadata
const commit = "";
- //res.sendFile(path.join(HOST_DIR, org, repo, branch, commit, "badge.svg"));
return res.status(501).send();
});
@@ -108,7 +103,6 @@ app.get("/v1/:org/:repo/:branch.html", (req, res) => {
//TODO @Metadata get the commit @@ via metadata
const commit = "";
- //res.sendFile(path.join(HOST_DIR, org, repo, branch, commit, "index.html"));
return res.status(501).send();
});
diff --git a/src/metadata.ts b/src/metadata.ts
deleted file mode 100644
index 353d9bf..0000000
--- a/src/metadata.ts
+++ /dev/null
@@ -1,3 +0,0 @@
-const metadata = {};
-
-export default metadata; \ No newline at end of file