QuickWho

Check-in [61fd87e53e]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Work on Services integration for macOS
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 61fd87e53ee377fcce8d0fa817c5183f06642bdc
User & Date: kevin 2020-02-06 14:27:19
Context
2020-02-09
02:24
Clean up services check-in: 4df2221454 user: kevin tags: trunk
2020-02-06
14:27
Work on Services integration for macOS check-in: 61fd87e53e user: kevin tags: trunk
03:32
Moving ahead on macOS check-in: 166533de43 user: kevin tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to QuickWho.py.

81
82
83
84
85
86
87

88
89
90
91
92
93
94
        if self.isAqua():
            self.tk.call('package', 'require', 'cocoaprint')
            self.tk.call('package', 'require', 'darkaqua')
        if self.isWindows():
            self.tk.call('package require dde')
            self.tk.eval('dde servername QuickWho')
        self.tk.createcommand('getDomain', self.getDomain)

        self.tk.call('package', 'require', 'regproc')
        self.tk.call('package', 'require', 'softwareupdate')
        self.tk.call('softwareupdate::setVersion', self.appname, self.appversion)
        self.tk.call('package', 'require', 'xplat')
        self.tk.call('package', 'require', 'Img')
        self.prefsdir = str(self.tk.call('xplat::appconfig', 'QuickWho'))
        self.cachedir = tempfile.gettempdir()







>







81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
        if self.isAqua():
            self.tk.call('package', 'require', 'cocoaprint')
            self.tk.call('package', 'require', 'darkaqua')
        if self.isWindows():
            self.tk.call('package require dde')
            self.tk.eval('dde servername QuickWho')
        self.tk.createcommand('getDomain', self.getDomain)
        self.tk.createcommand('tk::mac::PerformService', self.runService)
        self.tk.call('package', 'require', 'regproc')
        self.tk.call('package', 'require', 'softwareupdate')
        self.tk.call('softwareupdate::setVersion', self.appname, self.appversion)
        self.tk.call('package', 'require', 'xplat')
        self.tk.call('package', 'require', 'Img')
        self.prefsdir = str(self.tk.call('xplat::appconfig', 'QuickWho'))
        self.cachedir = tempfile.gettempdir()
588
589
590
591
592
593
594








595
596
597
598
599
    #expose basic functionality to AppleScript and dde
    def getDomain(self, domain):
        self.searchfield.delete(0, 'end')
        self.searchfield.insert(0, domain)
        self.getInfo()
        alltext=self.getData()
        return alltext









if __name__== '__main__':
    app = quickwhoApp(None)
    app.mainloop()








>
>
>
>
>
>
>
>





589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
    #expose basic functionality to AppleScript and dde
    def getDomain(self, domain):
        self.searchfield.delete(0, 'end')
        self.searchfield.insert(0, domain)
        self.getInfo()
        alltext=self.getData()
        return alltext

    #command for Services menu
    def runService(self):
        data = self.clipboard_get()
        self.searchfield.delete(0, 'end')
        self.searchfield.insert(0, data)
        self.getInfo()


if __name__== '__main__':
    app = quickwhoApp(None)
    app.mainloop()

Changes to buildapp.

67
68
69
70
71
72
73


















74
75
76
77
78
79
80
	<string>Copyright (c) 2020 WordTech Communications LLC</string>
	<key>NSMainNibFile</key>
	<string>MainMenu</string>
	<key>NSPrincipalClass</key>
	<string>NSApplication</string>
	<key>OSAScriptingDefinition</key>
	<string>Wish.sdef</string>


















</dict>
</plist>
EOT

python3 setup.py bdist_mac

cp Info.plist build/QuickWho.app/Contents/Info.plist







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
	<string>Copyright (c) 2020 WordTech Communications LLC</string>
	<key>NSMainNibFile</key>
	<string>MainMenu</string>
	<key>NSPrincipalClass</key>
	<string>NSApplication</string>
	<key>OSAScriptingDefinition</key>
	<string>Wish.sdef</string>
		<key>NSServices</key>
	<array>
		<dict>
			<key>NSMenuItem</key>
			<dict>
				<key>default</key>
				<string>QuickWho: Display Domain Information</string>
			</dict>
			<key>NSMessage</key>
			<string>provideService</string>
			<key>NSPortName</key>
			<string>QuickWho</string>
			<key>NSSendTypes</key>
			<array>
				<string>NSStringPboardType</string>
			</array>
		</dict>
	</array>
</dict>
</plist>
EOT

python3 setup.py bdist_mac

cp Info.plist build/QuickWho.app/Contents/Info.plist
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122

123
124
125
126
127
128
129

find build/QuickWho.app  -name "*.a"  -exec rm -rf {} \;
find build/QuickWho.app  -name "*debug"  -exec rm -rf {} \;
find build/QuickWho.app  -name "*.sh"  -exec rm -rf {} \; 

xattr -cr build/QuickWho.app

find build/QuickWho.app -type f -name "*.so"  -exec strip -x {} \;
find build/QuickWho.app -type f -name "*.so"  -exec codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" {} \;
find build/QuickWho.app -type f -name "*.dylib"  -exec strip -x  {} \;
find build/QuickWho.app -type f -name "*.dylib"  -exec codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" {} \; 

codesign  --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/Quickwho.app/Contents/MacOS/Tk
codesign  --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/Quickwho.app/Contents/MacOS/Tcl
codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/Quickwho.app/Contents/MacOS/Python
codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/Quickwho.app/Contents/MacOS/QuickWho


codesign   --deep --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" --verbose=2  --entitlements entitlements.plist build/QuickWho.app

#cp readme.txt build/readme.txt
#cd build
#ln -s /Applications Applications
#cd ../
 


echo "Creating and signing DMG file..."

#hdiutil create  -srcfolder build -fs HFS+ -volname QuickWho QuickWho.dmg

#codesign  --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" --verbose=2  QuickWho.dmg








|
|
|
|
|
|
|
|
|









>







116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148

find build/QuickWho.app  -name "*.a"  -exec rm -rf {} \;
find build/QuickWho.app  -name "*debug"  -exec rm -rf {} \;
find build/QuickWho.app  -name "*.sh"  -exec rm -rf {} \; 

xattr -cr build/QuickWho.app

# find build/QuickWho.app -type f -name "*.so"  -exec strip -x {} \;
# find build/QuickWho.app -type f -name "*.so"  -exec codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" {} \;
# find build/QuickWho.app -type f -name "*.dylib"  -exec strip -x  {} \;
# find build/QuickWho.app -type f -name "*.dylib"  -exec codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" {} \; 
# 
# codesign  --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/Quickwho.app/Contents/MacOS/Tk
# codesign  --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/Quickwho.app/Contents/MacOS/Tcl
# codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/Quickwho.app/Contents/MacOS/Python
# codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/Quickwho.app/Contents/MacOS/QuickWho


codesign   --deep --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" --verbose=2  --entitlements entitlements.plist build/QuickWho.app

#cp readme.txt build/readme.txt
#cd build
#ln -s /Applications Applications
#cd ../
 
rm -rf build/exe.macosx-10.15-x86_64-3.7

echo "Creating and signing DMG file..."

#hdiutil create  -srcfolder build -fs HFS+ -volname QuickWho QuickWho.dmg

#codesign  --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" --verbose=2  QuickWho.dmg