Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
bulletin
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Personal Projects
bulletin
Commits
d36a572c
Unverified
Commit
d36a572c
authored
2 months ago
by
Kevin Lyda
Browse files
Options
Downloads
Patches
Plain Diff
Permanent messages are permanent...
Sigh. Boolean errors strike again.
parent
7410cef1
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
NOTES.md
+3
-3
3 additions, 3 deletions
NOTES.md
storage/batch.sql.go
+2
-2
2 additions, 2 deletions
storage/batch.sql.go
storage/queries/batch.sql
+2
-2
2 additions, 2 deletions
storage/queries/batch.sql
with
7 additions
and
7 deletions
NOTES.md
+
3
−
3
View file @
d36a572c
...
@@ -20,9 +20,6 @@ Switch between MAIL and BULLETIN modes? MAIL commands are documented
...
@@ -20,9 +20,6 @@ Switch between MAIL and BULLETIN modes? MAIL commands are documented
## Things to do
## Things to do
*
Remove all file related things. Which means no need for most
(all?) /EDIT flags
*
Stop the seeded messages from being deleted by the expire batch command.
*
Run
[
godoc
](
http://localhost:6060/
)
and then review where the help text is lacking.
*
Run
[
godoc
](
http://localhost:6060/
)
and then review where the help text is lacking.
*
Implement each command.
*
Implement each command.
*
Next: folder commands - MODIFY
*
Next: folder commands - MODIFY
...
@@ -69,6 +66,9 @@ Done:
...
@@ -69,6 +66,9 @@ Done:
*
~~Remove BBOARD references.~~
*
~~Remove BBOARD references.~~
*
~~format with
`par w72j1`
~~
*
~~format with
`par w72j1`
~~
*
~~Handle MARK for SELECT and DIRECTORY.~~
*
~~Handle MARK for SELECT and DIRECTORY.~~
*
~~Remove all file related things. Which means no need for most
(all?) /EDIT flags~~
*
~~Stop the seeded messages from being deleted by the expire batch command.~~
## Module links
## Module links
...
...
This diff is collapsed.
Click to expand it.
storage/batch.sql.go
+
2
−
2
View file @
d36a572c
...
@@ -11,7 +11,7 @@ import (
...
@@ -11,7 +11,7 @@ import (
const
deleteAllExpiredMessages
=
`-- name: DeleteAllExpiredMessages :execrows
const
deleteAllExpiredMessages
=
`-- name: DeleteAllExpiredMessages :execrows
DELETE FROM messages
DELETE FROM messages
WHERE permanent !=
0
AND expiration < CURRENT_TIMESTAMP
WHERE permanent !=
1
AND expiration < CURRENT_TIMESTAMP
`
`
func
(
q
*
Queries
)
DeleteAllExpiredMessages
(
ctx
context
.
Context
)
(
int64
,
error
)
{
func
(
q
*
Queries
)
DeleteAllExpiredMessages
(
ctx
context
.
Context
)
(
int64
,
error
)
{
...
@@ -24,7 +24,7 @@ func (q *Queries) DeleteAllExpiredMessages(ctx context.Context) (int64, error) {
...
@@ -24,7 +24,7 @@ func (q *Queries) DeleteAllExpiredMessages(ctx context.Context) (int64, error) {
const
deleteAllShutdownMessages
=
`-- name: DeleteAllShutdownMessages :execrows
const
deleteAllShutdownMessages
=
`-- name: DeleteAllShutdownMessages :execrows
DELETE FROM messages
DELETE FROM messages
WHERE permanent !=
0
AND shutdown > 0
WHERE permanent !=
1
AND shutdown > 0
`
`
func
(
q
*
Queries
)
DeleteAllShutdownMessages
(
ctx
context
.
Context
)
(
int64
,
error
)
{
func
(
q
*
Queries
)
DeleteAllShutdownMessages
(
ctx
context
.
Context
)
(
int64
,
error
)
{
...
...
This diff is collapsed.
Click to expand it.
storage/queries/batch.sql
+
2
−
2
View file @
d36a572c
-- name: DeleteAllExpiredMessages :execrows
-- name: DeleteAllExpiredMessages :execrows
DELETE
FROM
messages
DELETE
FROM
messages
WHERE
permanent
!=
0
AND
expiration
<
CURRENT_TIMESTAMP
;
WHERE
permanent
!=
1
AND
expiration
<
CURRENT_TIMESTAMP
;
-- name: DeleteAllShutdownMessages :execrows
-- name: DeleteAllShutdownMessages :execrows
DELETE
FROM
messages
DELETE
FROM
messages
WHERE
permanent
!=
0
AND
shutdown
>
0
;
WHERE
permanent
!=
1
AND
shutdown
>
0
;
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment