Add the support for org-mode
This commit is contained in:
parent
4966e99079
commit
722a020352
12
flake.lock
12
flake.lock
|
@ -253,16 +253,16 @@
|
|||
"nixpkgs": "nixpkgs_4"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1712846008,
|
||||
"narHash": "sha256-0739q1QSpprLrlqdmQeSM9ynqmuqHagmRLnyMEy47Xc=",
|
||||
"ref": "refs/tags/v0.1.8",
|
||||
"rev": "e53688bcc79e5e3142bb2c912d59965c086dafe4",
|
||||
"revCount": 49,
|
||||
"lastModified": 1713211987,
|
||||
"narHash": "sha256-0Yx5n40Q6BymSRDxv4Bq/JRoXuDD4VJ/fTw2A55UbK8=",
|
||||
"ref": "refs/tags/v0.1.9",
|
||||
"rev": "f10112787fdf3e68b9dccf233c49d37b9e4b7d08",
|
||||
"revCount": 50,
|
||||
"type": "git",
|
||||
"url": "https://devheroes.codes/lxsameer/noether"
|
||||
},
|
||||
"original": {
|
||||
"ref": "refs/tags/v0.1.8",
|
||||
"ref": "refs/tags/v0.1.9",
|
||||
"type": "git",
|
||||
"url": "https://devheroes.codes/lxsameer/noether"
|
||||
}
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
description = "FG42 - Emacs Editor for advance users";
|
||||
|
||||
inputs.nixpkgs.url = "github:NixOS/nixpkgs/442d407992384ed9c0e6d352de75b69079904e4e";
|
||||
inputs.noether.url = "git+https://devheroes.codes/lxsameer/noether?ref=refs/tags/v0.1.8";
|
||||
inputs.noether.url = "git+https://devheroes.codes/lxsameer/noether?ref=refs/tags/v0.1.9";
|
||||
|
||||
inputs.emacs-overlay.url = "github:nix-community/emacs-overlay/0f7f3b39157419f3035a2dad39fbaf8a4ba0448d";
|
||||
inputs.flake-parts.url = "github:hercules-ci/flake-parts";
|
||||
|
@ -50,9 +50,10 @@
|
|||
'';
|
||||
};
|
||||
|
||||
#noether = inputs.noether.outputs.packages.${system}.default;
|
||||
fg42 = pkgs.callPackage ./nix/fg42 {
|
||||
#extraModules = inputs.noether.outputs.fg42Modules.default;
|
||||
extraPackages = {
|
||||
noether = inputs.noether.outputs.packages.${system}.default;
|
||||
};
|
||||
};
|
||||
|
||||
run-test-wm = pkgs.writeShellApplication {
|
||||
|
|
|
@ -80,6 +80,10 @@
|
|||
(defvar build-state '()
|
||||
"A list of expressions that will dump in the output at the end.")
|
||||
|
||||
(defvar vars ())
|
||||
(defvar requires ())
|
||||
|
||||
|
||||
(defvar build-output (cadr command-line-args-left))
|
||||
|
||||
;;; Build related stuff
|
||||
|
@ -98,14 +102,14 @@
|
|||
"Generate a list of `require' forms of ELISP-PKGS for compile time."
|
||||
(when (> (length elisp-pkgs) 0)
|
||||
(add-to-list
|
||||
'build-state
|
||||
'requires
|
||||
`(eval-when-compile
|
||||
,@(mapcar (lambda (pkg) `(require ',(intern pkg))) elisp-pkgs)))))
|
||||
|
||||
|
||||
(defun generate-generic-vars (k v doc)
|
||||
"Generate a list of vars for K and value V with docstring DOC."
|
||||
(add-to-list 'build-state `(defvar ,(intern (format "fg42/config/%s" k)) ,v ,doc)))
|
||||
(add-to-list 'vars `(defvar ,(intern (format "fg42/config/%s" k)) ,v ,doc)))
|
||||
|
||||
|
||||
(defun fg42-config-key-handler (config)
|
||||
|
@ -146,7 +150,10 @@ CONFIG maps to the collective `config' value of Nix modules."
|
|||
(maphash #'handle-top-level j)
|
||||
(with-temp-file build-output
|
||||
(insert file-header)
|
||||
(mapc (lambda (x) (print x (current-buffer))) build-state)
|
||||
(insert ";; Vars ======")
|
||||
(mapc (lambda (x) (print x (current-buffer))) vars)
|
||||
(insert ";; Requires ======")
|
||||
(mapc (lambda (x) (print x (current-buffer))) requires)
|
||||
(insert file-footer))
|
||||
(message "[build.el]: Done!"))
|
||||
|
||||
|
|
|
@ -17,7 +17,12 @@
|
|||
# This is the home manager module that exposes FG42. It differs
|
||||
# from FG42 modules that are structurally the same but used in
|
||||
# different context
|
||||
{ pkgs, lib ? pkgs.lib, modules ? null, extraModules ? [ ] }:
|
||||
{ pkgs
|
||||
, lib ? pkgs.lib
|
||||
, modules ? null
|
||||
, extraModules ? [ ]
|
||||
, extraPackages ? { }
|
||||
}:
|
||||
let
|
||||
fg42Modules =
|
||||
if modules != null
|
||||
|
@ -36,6 +41,7 @@ let
|
|||
specialArgs = {
|
||||
inherit utils;
|
||||
inherit (utils) makeFG42Drv;
|
||||
inherit extraPackages;
|
||||
};
|
||||
};
|
||||
in
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
# different context
|
||||
|
||||
# A list of default FG42 modules to build FG42 with.
|
||||
{ lib, config, pkgs, makeFG42Drv, ... }:
|
||||
{ lib, config, pkgs, makeFG42Drv, extraPackages, ... }:
|
||||
let
|
||||
deps =
|
||||
(with pkgs.emacsPackages; [
|
||||
|
@ -42,17 +42,23 @@ let
|
|||
vertico
|
||||
orderless
|
||||
ctrlf
|
||||
consult
|
||||
marginalia
|
||||
magit
|
||||
forge
|
||||
diff-hl
|
||||
svg-tag-mode
|
||||
all-the-icons
|
||||
org
|
||||
org-super-agenda
|
||||
org-ql
|
||||
org-modern
|
||||
base16-theme
|
||||
] ++ lib.optionals (config.fg42.emojify) [
|
||||
emojify
|
||||
] ++ lib.optionals (config.fg42.modeline == "noether") [
|
||||
noether
|
||||
posframe
|
||||
extraPackages.noether
|
||||
]);
|
||||
|
||||
drv = makeFG42Drv {
|
||||
|
|
|
@ -40,7 +40,7 @@
|
|||
(defmacro with-config (name &rest body)
|
||||
"Run the BODY only if the config NAME is set to t."
|
||||
(declare (indent defun))
|
||||
`(when (fg42/config-get-or ,name)
|
||||
`(when (string= (format "%s" (fg42/config-get-or ,name "")) "t")
|
||||
,@body))
|
||||
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@
|
|||
|
||||
(require 'fg42/git)
|
||||
;; (require 'fg42/wm)
|
||||
(require 'fg42/org)
|
||||
(require 'fg42/organize)
|
||||
(require 'fg42/minibuffer)
|
||||
(require 'fg42/graphics)
|
||||
(require 'fg42/modeline))
|
||||
|
|
|
@ -55,6 +55,7 @@ to Emacs modeline."
|
|||
:if (display-graphic-p)
|
||||
;;:after projectile
|
||||
:commands noether-global-mode
|
||||
:hook (emacs-startup . noether-global-mode)
|
||||
:config
|
||||
(require 'noether-views)
|
||||
(require 'fg42/modeline/views)
|
||||
|
@ -79,5 +80,6 @@ to Emacs modeline."
|
|||
(when-wm
|
||||
(setq-default noether-views nil)))
|
||||
|
||||
(provide 'fg42/modeline-noether.el)
|
||||
|
||||
(provide 'fg42/modeline-noether)
|
||||
;;; modeline-noether.el ends here
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
|
||||
(require 'fg42/utils)
|
||||
|
||||
|
||||
(if (string= (fg42/config-get-or modeline "") "noether")
|
||||
(require 'fg42/modeline-noether)
|
||||
(progn
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
(eval-when-compile
|
||||
(require 'fpkg))
|
||||
|
||||
|
||||
(defvar fg42/org-super-agenda-groups nil)
|
||||
|
||||
(defvar fg42/org-home "~/.orgs"
|
||||
|
@ -153,5 +154,5 @@ For more info on ~org-mode~ check out `https://orgmode.org/'"
|
|||
(org-agenda-finalize . org-modern-mode)))
|
||||
|
||||
|
||||
(provide 'fg42/org)
|
||||
;;; org.el ends here
|
||||
(provide 'fg42/organize)
|
||||
;;; organize.el ends here
|
Loading…
Reference in New Issue