Skip to content

Commit

Permalink
Remove redundant :group keywords
Browse files Browse the repository at this point in the history
* hackernews.el (hackernews-link, hackernews-link-visited)
(hackernews-comment-count, hackernews-comment-count-visited)
(hackernews-score, hackernews-items-per-page)
(hackernews-default-feed, hackernews-item-format)
(hackernews-score-format, hackernews-title-format)
(hackernews-comments-format, hackernews-preserve-point)
(hackernews-before-render-hook, hackernews-after-render-hook)
(hackernews-finalize-hook, hackernews-suppress-url-status)
(hackernews-internal-browser-function)
(hackernews-show-visited-links, hackernews-visited-links-file)
(hackernews-mode): Remove redundant :group customization keywords.
  • Loading branch information
basil-conto committed Jan 27, 2023
1 parent 7cdfbd0 commit dcb3121
Showing 1 changed file with 5 additions and 25 deletions.
30 changes: 5 additions & 25 deletions hackernews.el
Original file line number Diff line number Diff line change
Expand Up @@ -47,38 +47,33 @@
(defface hackernews-link
'((t :inherit link :underline nil))
"Face used for links to stories."
:package-version '(hackernews . "0.4.0")
:group 'hackernews)
:package-version '(hackernews . "0.4.0"))

(defface hackernews-link-visited
'((t :inherit link-visited :underline nil))
"Face used for visited links to stories."
:package-version '(hackernews . "0.5.0")
:group 'hackernews)
:package-version '(hackernews . "0.5.0"))

(define-obsolete-face-alias 'hackernews-comment-count-face
'hackernews-comment-count "0.4.0")

(defface hackernews-comment-count
'((t :inherit hackernews-link))
"Face used for comment counts."
:package-version '(hackernews . "0.4.0")
:group 'hackernews)
:package-version '(hackernews . "0.4.0"))

(defface hackernews-comment-count-visited
'((t :inherit hackernews-link-visited))
"Face used for visited comment counts."
:package-version '(hackernews . "0.5.0")
:group 'hackernews)
:package-version '(hackernews . "0.5.0"))

(define-obsolete-face-alias 'hackernews-score-face
'hackernews-score "0.4.0")

(defface hackernews-score
'((t :inherit default))
"Face used for the score of a story."
:package-version '(hackernews . "0.4.0")
:group 'hackernews)
:package-version '(hackernews . "0.4.0"))

;;;; User options

Expand All @@ -88,7 +83,6 @@
(defcustom hackernews-items-per-page 20
"Default number of stories to retrieve in one go."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'integer)

(defvar hackernews-feed-names
Expand All @@ -107,7 +101,6 @@
"Default story feed to load.
See `hackernews-feed-names' for supported feed types."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type (cons 'choice (mapcar (lambda (feed)
(list 'const :tag (cdr feed) (car feed)))
hackernews-feed-names)))
Expand All @@ -123,51 +116,44 @@ arguments to `format-spec':
%t - Item title; see `hackernews-title-format'.
%c - Item comments; see `hackernews-comments-format'."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'string)

(defcustom hackernews-score-format "[%s]"
"Format specification for displaying the score of an item.
The result is obtained by passing this string and the score count
to `format'."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'string)

(defcustom hackernews-title-format "%s"
"Format specification for displaying the title of an item.
The result is obtained by passing this string and the title to
`format'."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'string)

(defcustom hackernews-comments-format "(%s comments)"
"Format specification for displaying the comments of an item.
The result is obtained by passing this string and the comments
count to `format'."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'string)

(defcustom hackernews-preserve-point t
"Whether to preserve point when loading more stories.
When nil, point is placed on first new item retrieved."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'boolean)

(defcustom hackernews-before-render-hook ()
"Hook called before rendering any new items."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'hook)

(defcustom hackernews-after-render-hook ()
"Hook called after rendering any new items.
The position of point will not have been affected by the render."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'hook)

(defcustom hackernews-finalize-hook ()
Expand All @@ -176,7 +162,6 @@ The position of point may have been adjusted after the render,
buffer-local feed state will have been updated and the hackernews
buffer will be current and displayed in the selected window."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'hook)

(defcustom hackernews-suppress-url-status t
Expand All @@ -186,7 +171,6 @@ messages are displayed when retrieving online data. This is
suppressed by default so that the hackernews progress reporter is
not interrupted."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type 'boolean)

(defcustom hackernews-internal-browser-function
Expand All @@ -196,7 +180,6 @@ not interrupted."
"Function to load a given URL within Emacs.
See `browse-url-browser-function' for some possible options."
:package-version '(hackernews . "0.4.0")
:group 'hackernews
:type (cons 'radio (butlast (cdr (custom-variable-type
'browse-url-browser-function)))))

Expand All @@ -206,15 +189,13 @@ For example, when a link with the `hackernews-link' face is
visited and the value of this variable is non-nil, that link's
face is changed to `hackernews-link-visited'."
:package-version '(hackernews . "0.5.0")
:group 'hackernews
:type 'boolean)

(defcustom hackernews-visited-links-file
(locate-user-emacs-file "hackernews/visited-links.el")
"Name of file used to remember which links have been visited.
When nil, visited links are not persisted across sessions."
:package-version '(hackernews . "0.5.0")
:group 'hackernews
:type '(choice file (const :tag "None" nil)))

;;;; Internal definitions
Expand Down Expand Up @@ -621,7 +602,6 @@ key binding
Official major mode key bindings:
\\{hackernews-mode-map}"
:group 'hackernews
:interactive nil
(setq hackernews--feed-state ())
(setq truncate-lines t)
Expand Down

0 comments on commit dcb3121

Please sign in to comment.