mirror of
https://github.com/librephoenix/nixos-config
synced 2025-01-18 22:55:52 +05:30
Added org-sliced-images
This commit is contained in:
parent
9af1be6b69
commit
46387c6f57
17
flake.lock
17
flake.lock
|
@ -805,6 +805,22 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"org-sliced-images": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1711408181,
|
||||
"narHash": "sha256-ck3mGXtJJ0N8asGE4cRtWeJx5/iC+bTXw2cvZgePJqM=",
|
||||
"owner": "jcfk",
|
||||
"repo": "org-sliced-images",
|
||||
"rev": "bd1141d6df6edfd9749c0bbf3a72836148c0e39d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "jcfk",
|
||||
"repo": "org-sliced-images",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"org-timeblock": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
|
@ -918,6 +934,7 @@
|
|||
"org-krita": "org-krita",
|
||||
"org-nursery": "org-nursery",
|
||||
"org-side-tree": "org-side-tree",
|
||||
"org-sliced-images": "org-sliced-images",
|
||||
"org-timeblock": "org-timeblock",
|
||||
"org-yaap": "org-yaap",
|
||||
"phscroll": "phscroll",
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
outputs = inputs@{ self, nixpkgs, nixpkgs-stable, emacs-pin-nixpkgs, kdenlive-pin-nixpkgs,
|
||||
home-manager-unstable, home-manager-stable, nix-doom-emacs,
|
||||
nix-straight, stylix, blocklist-hosts, rust-overlay, org-nursery, org-yaap,
|
||||
org-side-tree, org-timeblock, org-krita, phscroll, mini-frame, ... }:
|
||||
org-side-tree, org-timeblock, org-krita, org-sliced-images, phscroll, mini-frame, ... }:
|
||||
let
|
||||
# ---- SYSTEM SETTINGS ---- #
|
||||
systemSettings = {
|
||||
|
@ -138,6 +138,7 @@
|
|||
inherit (inputs) org-side-tree;
|
||||
inherit (inputs) org-timeblock;
|
||||
inherit (inputs) org-krita;
|
||||
inherit (inputs) org-sliced-images;
|
||||
inherit (inputs) phscroll;
|
||||
inherit (inputs) mini-frame;
|
||||
#inherit (inputs) nix-flatpak;
|
||||
|
@ -232,6 +233,10 @@
|
|||
url = "github:lepisma/org-krita";
|
||||
flake = false;
|
||||
};
|
||||
org-sliced-images = {
|
||||
url = "github:jcfk/org-sliced-images";
|
||||
flake = false;
|
||||
};
|
||||
phscroll = {
|
||||
url = "github:misohena/phscroll";
|
||||
flake = false;
|
||||
|
|
|
@ -272,7 +272,7 @@
|
|||
org-pretty-entities t
|
||||
org-ellipsis "…")
|
||||
|
||||
(setq-default line-spacing 0.15)
|
||||
(setq-default line-spacing 0)
|
||||
|
||||
; Automatic table of contents is nice
|
||||
(if (require 'toc-org nil t)
|
||||
|
@ -482,6 +482,12 @@ If FULL-MODE is not null, run full krita."
|
|||
:desc "Copy link/file at point into system clipbord (C-g to escape if copying a file)"
|
||||
"y y" 'org-copy-link-to-clipboard-at-point))
|
||||
|
||||
(add-load-path! "~/.emacs.d/org-sliced-images")
|
||||
(require 'org-sliced-images)
|
||||
(defalias 'org-remove-inline-images #'org-sliced-images-remove-inline-images)
|
||||
(defalias 'org-toggle-inline-images #'org-sliced-images-toggle-inline-images)
|
||||
(defalias 'org-display-inline-images #'org-sliced-images-display-inline-images)
|
||||
|
||||
;; Online images inside of org mode is pretty cool
|
||||
;; This snippit is from Tobias on Stack Exchange
|
||||
;; https://emacs.stackexchange.com/questions/42281/org-mode-is-it-possible-to-display-online-images
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{ config, lib, pkgs-emacs, pkgs-stable, userSettings, systemSettings,
|
||||
org-nursery, org-yaap, org-side-tree, org-timeblock, org-krita, phscroll, mini-frame, ... }:
|
||||
org-nursery, org-yaap, org-side-tree, org-timeblock, org-krita, org-sliced-images, phscroll, mini-frame, ... }:
|
||||
let
|
||||
themePolarity = lib.removeSuffix "\n" (builtins.readFile (./. + "../../../../themes"+("/"+userSettings.theme)+"/polarity.txt"));
|
||||
dashboardLogo = ./. + "/nix-" + themePolarity + ".png";
|
||||
|
@ -101,6 +101,10 @@ in
|
|||
source = "${org-krita}";
|
||||
};
|
||||
|
||||
home.file.".emacs.d/org-sliced-images" = {
|
||||
source = "${org-sliced-images}";
|
||||
};
|
||||
|
||||
home.file.".emacs.d/dashboard-logo.png".source = dashboardLogo;
|
||||
home.file.".emacs.d/scripts/copy-link-or-file/copy-link-or-file-to-clipboard.sh" = {
|
||||
source = ./scripts/copy-link-or-file/copy-link-or-file-to-clipboard.sh;
|
||||
|
|
|
@ -342,7 +342,7 @@ Doom Emacs is traditionally installed by cloning the repository ([[https://githu
|
|||
org-pretty-entities t
|
||||
org-ellipsis "…")
|
||||
|
||||
(setq-default line-spacing 0.15)
|
||||
(setq-default line-spacing 0)
|
||||
|
||||
; Automatic table of contents is nice
|
||||
(if (require 'toc-org nil t)
|
||||
|
@ -587,6 +587,14 @@ else
|
|||
fi
|
||||
exit
|
||||
#+END_SRC
|
||||
*** Org Sliced Images
|
||||
#+begin_src emacs-lisp :tangle config.el
|
||||
(add-load-path! "~/.emacs.d/org-sliced-images")
|
||||
(require 'org-sliced-images)
|
||||
(defalias 'org-remove-inline-images #'org-sliced-images-remove-inline-images)
|
||||
(defalias 'org-toggle-inline-images #'org-sliced-images-toggle-inline-images)
|
||||
(defalias 'org-display-inline-images #'org-sliced-images-display-inline-images)
|
||||
#+end_src
|
||||
*** Org Online Images
|
||||
#+BEGIN_SRC emacs-lisp :tangle config.el
|
||||
;; Online images inside of org mode is pretty cool
|
||||
|
@ -1994,7 +2002,7 @@ Any git package can be configured for a particular commit or branch:
|
|||
In order to have Nix load my Doom Emacs configuration [[./doom.nix][doom.nix]], which I source in the =imports= block of my [[../../../profiles/work/home.nix][home.nix]].
|
||||
#+BEGIN_SRC nix :tangle doom.nix
|
||||
{ config, lib, pkgs-emacs, pkgs-stable, userSettings, systemSettings,
|
||||
org-nursery, org-yaap, org-side-tree, org-timeblock, org-krita, phscroll, mini-frame, ... }:
|
||||
org-nursery, org-yaap, org-side-tree, org-timeblock, org-krita, org-sliced-images, phscroll, mini-frame, ... }:
|
||||
let
|
||||
themePolarity = lib.removeSuffix "\n" (builtins.readFile (./. + "../../../../themes"+("/"+userSettings.theme)+"/polarity.txt"));
|
||||
dashboardLogo = ./. + "/nix-" + themePolarity + ".png";
|
||||
|
@ -2096,6 +2104,10 @@ in
|
|||
source = "${org-krita}";
|
||||
};
|
||||
|
||||
home.file.".emacs.d/org-sliced-images" = {
|
||||
source = "${org-sliced-images}";
|
||||
};
|
||||
|
||||
home.file.".emacs.d/dashboard-logo.png".source = dashboardLogo;
|
||||
home.file.".emacs.d/scripts/copy-link-or-file/copy-link-or-file-to-clipboard.sh" = {
|
||||
source = ./scripts/copy-link-or-file/copy-link-or-file-to-clipboard.sh;
|
||||
|
|
Loading…
Reference in a new issue