From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 37894 invoked by alias); 28 Sep 2015 16:46:47 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 37880 invoked by uid 89); 28 Sep 2015 16:46:47 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=0.0 required=5.0 tests=BAYES_20,KAM_INFOUSMEBIZ,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 X-HELO: homiemail-a115.g.dreamhost.com Received: from sub5.mail.dreamhost.com (HELO homiemail-a115.g.dreamhost.com) (208.113.200.129) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 28 Sep 2015 16:46:45 +0000 Received: from homiemail-a115.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a115.g.dreamhost.com (Postfix) with ESMTP id 340134E40 for ; Mon, 28 Sep 2015 09:46:44 -0700 (PDT) Received: from [192.168.1.20] (68-168-161-249.fttp.usinternet.com [68.168.161.249]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: dd-b@dd-b.net) by homiemail-a115.g.dreamhost.com (Postfix) with ESMTPSA id 069374E4E for ; Mon, 28 Sep 2015 09:46:43 -0700 (PDT) To: cygwin@cygwin.com From: David Dyer-Bennet Subject: Regtool can't set default value? Message-ID: <56096E62.2030606@dd-b.net> Date: Mon, 28 Sep 2015 16:46:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2015-09/txt/msg00495.txt.bz2 I'm not sure I'm understanding this right. I'm trying to duplicate a manual setup that works (for making text files in general have an edit right-click option that invokes emacsclientw). In that manual setup, (sorry, using cygwin path notation while referring to regedit, of course in regedit the path shows in Windows notation) I've set up /root/txtfile/shell/edit/command with a value named "(Default)" of type REG_EXPAND_SQ whose data is a (windows-style of course) path to emacsclientw.exe (plus some switches plus "%1" for the file name at the end). That works -- the right-click menu for a file known to Windows as a txtfile (like foo.txt) has an "edit" entry, which when clicked invokes emacsclientw. I'm trying to create this in a script using cygwin regtool. I can create a key of /root/txtfile/shell/edit with a value of command having the right data -- but that of course does not work. I can create a key of /root/txtfile/shell/edit/command with *two* values named (Default), the second of which is my value -- but that also does not work. (And I can't delete the first value (Default) even in regedit.) I clearly don't understand something about the data that Regedit displays under the name (Default), and how to create, delete, get, and set value to it. How do I create this simple scenario using regtool? (It's not actually emacs-specific, if you look at the default Windows registry for /root/txtfile/shell/open/command you'll find a value named "(Default)" of type REG_EXPAND_SZ giving a path to notepad.exe. If I wanted to produce that using regtool, how would I do that?) (If there's no way to do it with regtool, that's weird, and in particular a huge deficit in regtool since configuring preferred handling of various file-types seems like one of the things you'd really want to be able to do. (It *ought* to be possible for my script to write a .reg file that it then feeds to regedit as an alternative way to do it, and if I can't make regtool work I'll try that, but I don't need suggestions about that, at least not yet -- I know how to do that, but am currently trying to understand regtool, and will only give up if we determine fairly authoritatively that regtool can't do what I need.) -- David Dyer-Bennet, dd-b@dd-b.net; http://dd-b.net/ Snapshots: http://dd-b.net/dd-b/SnapshotAlbum/data/ Photos: http://dd-b.net/photography/gallery/ Dragaera: http://dragaera.info Nikon DSLR photo list: http://d4scussion.com -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple