Skip to content

Commit

Permalink
make the rule category an enum
Browse files Browse the repository at this point in the history
  • Loading branch information
marcorosa committed Oct 14, 2021
1 parent 9e005a4 commit 8bf9481
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sql/create_table.sql
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
CREATE TYPE STATES AS ENUM ('new', 'false_positive', 'addressing', 'not_relevant', 'fixed');
CREATE TYPE CATEGORIES AS ENUM ('password', 'token', 'crypto_key', 'other');

CREATE TABLE repos (
url TEXT NOT NULL UNIQUE,
Expand All @@ -9,7 +10,7 @@ CREATE TABLE repos (
CREATE TABLE rules (
id SERIAL NOT NULL UNIQUE,
regex TEXT NOT NULL UNIQUE,
category VARCHAR(50),
category CATEGORIES,
description TEXT,
PRIMARY KEY (id)
);
Expand Down

0 comments on commit 8bf9481

Please sign in to comment.