emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* emacs , windows, gpg, org-crypt
@ 2018-03-29 13:59 hymie!
  2018-03-29 14:45 ` Adonay Felipe Nogueira
  2018-03-29 15:59 ` Jonathan Leech-Pepin
  0 siblings, 2 replies; 4+ messages in thread
From: hymie! @ 2018-03-29 13:59 UTC (permalink / raw)
  To: emacs-orgmode

Greetings.

I set this all up years ago, I just got a new computer, I'm not an expert
with Windows, and I've been unable to find my problem with Google.

I have Windows 10, I have emacs, I have Org 9.0.3 (yes, I need to update),
and I have GPG4Win.  I have entries in my .emacs file:

     (require 'org-crypt)
     (org-crypt-use-before-save-magic)
     (setq org-tags-exclude-from-inheritance (quote ("crypt")))
     [...]
     (setq org-crypt-key "xxxxxxxx")
       ;; GPG key to use for encryption
     [...]
     (global-set-key "\C-cd" 'org-decrypt-entry)
     (global-set-key "\C-ce" 'org-encrypt-entry)

But when I try to decrypt something, I get this error:

  Searching for program: no such file or directory, gpg

The only responses I can find are to add gpg to my %PATH% , but
I don't think my employer's GPO will let me.

I was hoping to find a place in org-crypt where "gpg" is defined so that
I can specify a full path instead, but as yet, I haven't found it.

Can somebody give me a push?

--hymie!     http://lactose.homelinux.net/~hymie    hymie@lactose.homelinux.net

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: emacs , windows, gpg, org-crypt
  2018-03-29 13:59 emacs , windows, gpg, org-crypt hymie!
@ 2018-03-29 14:45 ` Adonay Felipe Nogueira
  2018-03-29 15:59 ` Jonathan Leech-Pepin
  1 sibling, 0 replies; 4+ messages in thread
From: Adonay Felipe Nogueira @ 2018-03-29 14:45 UTC (permalink / raw)
  To: emacs-orgmode

> The only responses I can find are to add gpg to my %PATH% , but

That's the most recommended way.

> I don't think my employer's GPO will let me.

That's very limitting indeed. In various GNU+Linux system distributions,
even the user-friendly ones such as Trisquel ([1]), allow each user to
have their own ${PATH}.

I cannot help you on solving Windows only-issues (not to be confused
with: Emacs or Org mode issues manifested in Windows), so I suggest you
to install a free/libre system distribution such as Trisquel ([1])
instead.

[1] <https://trisquel.info/en>.

-- 
- https://libreplanet.org/wiki/User:Adfeno
- Palestrante e consultor sobre /software/ livre (não confundir com
  gratis).
- "WhatsApp"? Ele não é livre. Por favor, veja formas de se comunicar
  instantaneamente comigo no endereço abaixo.
- Contato: https://libreplanet.org/wiki/User:Adfeno#vCard
- Arquivos comuns aceitos (apenas sem DRM): Corel Draw, Microsoft
  Office, MP3, MP4, WMA, WMV.
- Arquivos comuns aceitos e enviados: CSV, GNU Dia, GNU Emacs Org, GNU
  GIMP, Inkscape SVG, JPG, LibreOffice (padrão ODF), OGG, OPUS, PDF
  (apenas sem DRM), PNG, TXT, WEBM.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: emacs , windows, gpg, org-crypt
  2018-03-29 13:59 emacs , windows, gpg, org-crypt hymie!
  2018-03-29 14:45 ` Adonay Felipe Nogueira
@ 2018-03-29 15:59 ` Jonathan Leech-Pepin
  2018-03-29 16:17   ` hymie!
  1 sibling, 1 reply; 4+ messages in thread
From: Jonathan Leech-Pepin @ 2018-03-29 15:59 UTC (permalink / raw)
  To: hymie!; +Cc: Org Mode Mailing List

[-- Attachment #1: Type: text/plain, Size: 1628 bytes --]

On 29 March 2018 at 09:59, hymie! <hymie@lactose.homelinux.net> wrote:

> Greetings.
>
> I set this all up years ago, I just got a new computer, I'm not an expert
> with Windows, and I've been unable to find my problem with Google.
>
> I have Windows 10, I have emacs, I have Org 9.0.3 (yes, I need to update),
> and I have GPG4Win.  I have entries in my .emacs file:
>
>      (require 'org-crypt)
>      (org-crypt-use-before-save-magic)
>      (setq org-tags-exclude-from-inheritance (quote ("crypt")))
>      [...]
>      (setq org-crypt-key "xxxxxxxx")
>        ;; GPG key to use for encryption
>      [...]
>      (global-set-key "\C-cd" 'org-decrypt-entry)
>      (global-set-key "\C-ce" 'org-encrypt-entry)
>
> But when I try to decrypt something, I get this error:
>
>   Searching for program: no such file or directory, gpg
>
> The only responses I can find are to add gpg to my %PATH% , but
> I don't think my employer's GPO will let me.


There is a machine/system %PATH% and a Current User %PATH%.
Normally GPOs will block you from modifying the system %PATH% but
allow you to change the User Path.  This may be an option.

I was hoping to find a place in org-crypt where "gpg" is defined so that
> I can specify a full path instead, but as yet, I haven't found it.


I'd take a look at ~C-h v -gpg TAB~ -> possible suggestion is
epg-gpg-program which points to "gpg" by default.
~org-encrypt-string~ uses epg for encryption purposes so changing
that program path should fix the issue.

--
Jon


> Can somebody give me a push?
>
> --hymie!     http://lactose.homelinux.net/~hymie
> hymie@lactose.homelinux.net
>
>
>

[-- Attachment #2: Type: text/html, Size: 2777 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: emacs , windows, gpg, org-crypt
  2018-03-29 15:59 ` Jonathan Leech-Pepin
@ 2018-03-29 16:17   ` hymie!
  0 siblings, 0 replies; 4+ messages in thread
From: hymie! @ 2018-03-29 16:17 UTC (permalink / raw)
  To: emacs-orgmode


Thank you!!!!!  Your suggestion led me to the answer.

In our last episode, the evil Dr. Lacto had captured our hero,
  Jonathan Leech-Pepin <jonathan.leechpepin@gmail.com>, who said:

> On 29 March 2018 at 09:59, hymie! <hymie@lactose.homelinux.net> wrote:
>
>> Greetings.
>>
>> I set this all up years ago, I just got a new computer, I'm not an expert
>> with Windows, and I've been unable to find my problem with Google.
>>
>> I have Windows 10, I have emacs, I have Org 9.0.3 (yes, I need to update),
>> and I have GPG4Win.  I have entries in my .emacs file:

I missed the most important entry in my .emacs file:
  (setq exec-path '("C:\\Program Files (x86)\\GNU\\GnuPG"))

The file path has changed on my new computer
  (setq exec-path '("C:\\Program Files (x86)\\GnuPG\\bin"))

and now gpg.exe is in emacs's local exec-path.

> I'd take a look at ~C-h v -gpg TAB~ -> possible suggestion is
> epg-gpg-program which points to "gpg" by default.

This was the variable I couldn't figure out.  TIL that you can tab-complete
in the middle of a variable too.

--hymie!     http://lactose.homelinux.net/~hymie    hymie@lactose.homelinux.net

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-03-29 16:19 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-29 13:59 emacs , windows, gpg, org-crypt hymie!
2018-03-29 14:45 ` Adonay Felipe Nogueira
2018-03-29 15:59 ` Jonathan Leech-Pepin
2018-03-29 16:17   ` hymie!

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).