From 73bbdd81d5b155f798e4538a2305f51c3289826e Mon Sep 17 00:00:00 2001 From: Ryan Dotson Date: Tue, 30 Jul 2019 09:37:32 +0900 Subject: [PATCH 1/3] Helpbook: Add contributing, reading, news and deleting feeds - added pages to Helpbook - deleting feeds - getting NetNewsWire news - reading articles - contributing - updated index - updated other pages for consistency --- .../HelpBook/5.0/en/adding-feeds.markdown | 2 +- .../HelpBook/5.0/en/contributing.markdown | 15 +++++++ .../5.0/en/deleting-feeds-folders.markdown | 9 +++++ Technotes/HelpBook/5.0/en/index.markdown | 10 ++--- .../HelpBook/5.0/en/netnewswire-news.markdown | 13 +++++++ .../HelpBook/5.0/en/reading-articles.markdown | 39 +++++++++++++++++++ .../HelpBook/5.0/en/safari-extension.markdown | 2 +- 7 files changed, 83 insertions(+), 7 deletions(-) create mode 100644 Technotes/HelpBook/5.0/en/contributing.markdown create mode 100644 Technotes/HelpBook/5.0/en/deleting-feeds-folders.markdown create mode 100644 Technotes/HelpBook/5.0/en/netnewswire-news.markdown create mode 100644 Technotes/HelpBook/5.0/en/reading-articles.markdown diff --git a/Technotes/HelpBook/5.0/en/adding-feeds.markdown b/Technotes/HelpBook/5.0/en/adding-feeds.markdown index 8e16460b8..46a93f964 100644 --- a/Technotes/HelpBook/5.0/en/adding-feeds.markdown +++ b/Technotes/HelpBook/5.0/en/adding-feeds.markdown @@ -6,7 +6,7 @@ NetNewsWire collects items for you from feeds published on web sites. To do this *It’s okay if you don’t know that.* NetNewsWire will look at any web page and try to find it for you. All you need to give is the site’s URL, like `inessential.com`. -To get started, click the Add Feed button on the toolbar, or use File → New Feed (⌘-N) from the menu bar. +To get started, click the Add Feed button on the toolbar, or use **File → New Feed** (⌘-N) from the menu bar. If you’ve got the address already – great! Type it or paste it into the URL box. Otherwise, just enter the website’s address into the box. diff --git a/Technotes/HelpBook/5.0/en/contributing.markdown b/Technotes/HelpBook/5.0/en/contributing.markdown new file mode 100644 index 000000000..9396299ea --- /dev/null +++ b/Technotes/HelpBook/5.0/en/contributing.markdown @@ -0,0 +1,15 @@ +@title Contributing + +# Contributing + +NetNewsWire is open-source and contributions from the community are welcomed. + +There are two channels for contributing. There is a Slack group for conducting discussions. For filing tickets, and contributing code or documentation, we use GitHub. + +## Slack + +[Join the Slack group](https://join.slack.com/t/netnewswire/shared_invite/enQtNjM4MDA1MjQzMDkzLTNlNjBhOWVhYzdhYjA4ZWFhMzQ1MTUxYjU0NTE5ZGY0YzYwZWJhNjYwNTNmNTg2NjIwYWY4YzhlYzk5NmU3ZTc) to talk with other NetNewsWire users — and to help out, if you’d like to, by testing, coding, writing, providing feedback, or just helping us think things through. Everybody is welcome and encouraged to join. + +## GitHub + +The [NetNewsWire project on GitHub](https://github.com/brentsimmons/NetNewsWire) is the place to raise formal issues like bugs and feature requests. If you want to make contributions to NetNewsWire’s code or documentation, please refer to our [contribution guidelines](https://github.com/brentsimmons/NetNewsWire/blob/master/CONTRIBUTING.md) page on GitHub. \ No newline at end of file diff --git a/Technotes/HelpBook/5.0/en/deleting-feeds-folders.markdown b/Technotes/HelpBook/5.0/en/deleting-feeds-folders.markdown new file mode 100644 index 000000000..2679a5a24 --- /dev/null +++ b/Technotes/HelpBook/5.0/en/deleting-feeds-folders.markdown @@ -0,0 +1,9 @@ +@title Deleting feeds and folders + +# Deleting feeds and folders + +To delete a feed or folder, select it from the subscription list and choose **Edit → Delete** from the menu bar. Alternatively, select the feed and press the **delete** key. + +## Undo deleting a feed or folder + +If you change your mind, you can undo the deletion by selecting **Edit → Undo** in the menu bar or pressing ⌘-Z. \ No newline at end of file diff --git a/Technotes/HelpBook/5.0/en/index.markdown b/Technotes/HelpBook/5.0/en/index.markdown index f1ba76010..e975f5b62 100644 --- a/Technotes/HelpBook/5.0/en/index.markdown +++ b/Technotes/HelpBook/5.0/en/index.markdown @@ -11,19 +11,19 @@ More topics to do… [How to import OPML](import-opml.html) -How to export OPML +[How to export OPML](export-opml.html) -How to go through your articles (take special note of the space bar and the n key) +[How to go through your articles](reading-articles.html) Sharing to other apps, including MarsEdit and Micro.blog -How to delete feeds and folders (note that undo is available) +[How to delete feeds and folders](deleting-feeds-folders.html) How to add a syncing account -How to contribute (GitHub, Slack) +[How to contribute](contributing.html) -How to get NetNewsWire news (see Help menu command) +[How to get NetNewsWire news](netnewswire-news.html) Keyboard shortcuts (see Help menu command) diff --git a/Technotes/HelpBook/5.0/en/netnewswire-news.markdown b/Technotes/HelpBook/5.0/en/netnewswire-news.markdown new file mode 100644 index 000000000..647a4d54a --- /dev/null +++ b/Technotes/HelpBook/5.0/en/netnewswire-news.markdown @@ -0,0 +1,13 @@ +@title How to get NetNewsWire news + +# How to get NetNewsWire news + +The very best way to get news about NetNewsWire is with NetNewsWire itself, using the *NetNewsWire News Feed*. Important and notable news about NetNewsWire will appear there: new version announcements, critical bug notices, tech notes and important project announcements. + +## Add the NetNewsWire News Feed + +The NetNewsWire News Feed is part of the default subscription list installed the first time you launched NetNewsWire. If it’s no longer in your list, it’s easy to add it back. + +In the menu bar, select **Help → Add NetNewsWire News Feed**. NetNewsWire will open the [New Feed dialog](adding-feeds.html) pre-filled with the name and address (`https://nnw.ranchero.com/feed.json`). Click Add. + +Now you’ll always be up to date with what’s happening with NetNewsWire. \ No newline at end of file diff --git a/Technotes/HelpBook/5.0/en/reading-articles.markdown b/Technotes/HelpBook/5.0/en/reading-articles.markdown new file mode 100644 index 000000000..687f241f8 --- /dev/null +++ b/Technotes/HelpBook/5.0/en/reading-articles.markdown @@ -0,0 +1,39 @@ +@title How to go through your articles + +# How to go through your articles in NetNewsWire + +NetNewsWire was built to make it easy to read your articles one-handed. This is perfect for when your other hand is occupied with a warm drink or an insistent furry friend. + +One-handed reading is accomplished with keyboard shortcuts. NetNewsWire’s shortcuts are special because they only require pressing *a single key*. + +(For a full list of keyboard shortcuts, including Command (⌘) key alternatives, see the [Keyboard Shortcuts](keyboard-shortcuts.html) help page, or use **Help → Keyboard Shortcuts** in NetNewsWire.) + + +## Use the Space bar + +The easiest way to read articles in NetNewsWire is using the **space bar**. + +If you’re reading an article that can be scrolled, pressing **space bar** will scroll it – just like it would in Safari. If you’re at the end of the article, **space bar** will take you to the next unread article. + + +## Go to Next Unread + +Sometimes you may want to skip reading an article entirely – that’s totally fine! Rather than press space bar multiple times, you can jump directly to the next unread item by pressing ⌘-/ or just press **n** or **+**. + +If you want to skip the article for now, but plan to come back to it later, the **m** key is for you. Pressing it will mark the current article as unread and then go to the *next unread* item. + + +## Moving around lists + +You may not always want to read linearly – imagine there’s a new article on [Julia Evans’](https://jvns.ca) site you want to read first. You still don’t need to leave the keyboard. + +Pressing the left and right arrow keys will move you between the three panes in the NetNewsWire interface. Those panes are, from the left, the subscriptions list (sidebar), articles list timeline (centre pane) and the full article detail pane (right). The selected item’s highlight colour gives you a hint to which pane is active. + +In the subscription and article lists, the up and down arrow keys will change the currently selected item. + + +## Marking as read or unread + +As you zip through the NetNewsWire interface, you may want to mark an article as read or unread. The easiest way to do this is use the **r** and **u** keys, respectively. + +Again, see the [Keyboard Shortcuts](keyboard-shortcuts.html) help page or **Help → Keyboard Shortcuts** in NetNewsWire for a full list of keyboard shortcuts. \ No newline at end of file diff --git a/Technotes/HelpBook/5.0/en/safari-extension.markdown b/Technotes/HelpBook/5.0/en/safari-extension.markdown index 71d80ca86..251582c78 100644 --- a/Technotes/HelpBook/5.0/en/safari-extension.markdown +++ b/Technotes/HelpBook/5.0/en/safari-extension.markdown @@ -12,7 +12,7 @@ The Safari Extension is installed automatically with NetNewsWire. However, it mu You will enable the extension in Safari: 1. Open Safari -2. Click on the **Safari** menu and select **Preferences…** (⌘,) +2. Click on the **Safari** menu and select **Preferences…** (⌘-,) 3. Click the **Extensions** panel 4. From the list, click the checkbox beside **Subscribe to Feed** to enable the extension 5. Close the Preferences window From 31e089fc1df1a30d4a924b8304eea896a92dabf3 Mon Sep 17 00:00:00 2001 From: Brent Simmons Date: Mon, 29 Jul 2019 19:56:22 -0700 Subject: [PATCH 2/3] Add an active property to the scripting definition for Account. --- Mac/Resources/NetNewsWire.sdef | 5 ++++- Mac/Scriptability/Account+Scriptability.swift | 12 +++++++++++- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/Mac/Resources/NetNewsWire.sdef b/Mac/Resources/NetNewsWire.sdef index c025b6e1d..5a754f993 100644 --- a/Mac/Resources/NetNewsWire.sdef +++ b/Mac/Resources/NetNewsWire.sdef @@ -84,7 +84,10 @@ - + + + + diff --git a/Mac/Scriptability/Account+Scriptability.swift b/Mac/Scriptability/Account+Scriptability.swift index a89e59522..9513e3fab 100644 --- a/Mac/Scriptability/Account+Scriptability.swift +++ b/Mac/Scriptability/Account+Scriptability.swift @@ -25,7 +25,17 @@ class ScriptableAccount: NSObject, UniqueIdScriptingObject, ScriptingObjectConta let scriptObjectSpecifier = myContainer.makeFormUniqueIDScriptObjectSpecifier(forObject:self) return (scriptObjectSpecifier) } - + + @objc(scriptingIsActive) + var scriptingIsActive: Bool { + get { + return account.isActive + } + set { + account.isActive = newValue + } + } + // MARK: --- ScriptingObject protocol --- var scriptingKey: String { From badd7862b9d07d5624390f1d4717581b5610540c Mon Sep 17 00:00:00 2001 From: Olof Hellman Date: Tue, 30 Jul 2019 21:05:30 -0700 Subject: [PATCH 3/3] fix failing tests Disable the test that requires permissions to send keystrokes via SystemEvents.app Add PRODUCT_NAME back to the .pbxproj files to work around Xcode 11 beta 4 bug --- NetNewsWire.xcodeproj/project.pbxproj | 6 +++++- .../xcshareddata/xcschemes/NetNewsWire.xcscheme | 8 ++++---- .../ScriptingTests/ScriptingTests.swift | 10 +++++++++- 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/NetNewsWire.xcodeproj/project.pbxproj b/NetNewsWire.xcodeproj/project.pbxproj index 98ead857b..706e0bdaa 100644 --- a/NetNewsWire.xcodeproj/project.pbxproj +++ b/NetNewsWire.xcodeproj/project.pbxproj @@ -845,7 +845,7 @@ 849A97971ED9EFAA007D329B /* Node-Extensions.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "Node-Extensions.swift"; sourceTree = ""; }; 849A979E1ED9F130007D329B /* SidebarCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SidebarCell.swift; sourceTree = ""; }; 849A97A11ED9F180007D329B /* FolderTreeControllerDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = FolderTreeControllerDelegate.swift; sourceTree = ""; }; - 849C64601ED37A5D003D8FC0 /* NetNewsWire.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; name = NetNewsWire.app; path = .app; sourceTree = BUILT_PRODUCTS_DIR; }; + 849C64601ED37A5D003D8FC0 /* NetNewsWire.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = NetNewsWire.app; sourceTree = BUILT_PRODUCTS_DIR; }; 849C64671ED37A5D003D8FC0 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 849C64711ED37A5D003D8FC0 /* NetNewsWireTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = NetNewsWireTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 849EE70E203919360082A1EA /* AppAssets.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppAssets.swift; sourceTree = ""; }; @@ -2801,6 +2801,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = 51121AA12265430A00BC0EC1 /* NetNewsWire_iOSapp_target.xcconfig */; buildSettings = { + PRODUCT_NAME = NetNewsWire; }; name = Debug; }; @@ -2808,6 +2809,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = 51121AA12265430A00BC0EC1 /* NetNewsWire_iOSapp_target.xcconfig */; buildSettings = { + PRODUCT_NAME = NetNewsWire; }; name = Release; }; @@ -2829,6 +2831,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = D5907CE02002F0FA005947E5 /* NetNewsWire_macapp_target.xcconfig */; buildSettings = { + PRODUCT_NAME = NetNewsWire; }; name = Debug; }; @@ -2836,6 +2839,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = D5907CE02002F0FA005947E5 /* NetNewsWire_macapp_target.xcconfig */; buildSettings = { + PRODUCT_NAME = NetNewsWire; }; name = Release; }; diff --git a/NetNewsWire.xcodeproj/xcshareddata/xcschemes/NetNewsWire.xcscheme b/NetNewsWire.xcodeproj/xcshareddata/xcschemes/NetNewsWire.xcscheme index 07e988391..230b6714a 100644 --- a/NetNewsWire.xcodeproj/xcshareddata/xcschemes/NetNewsWire.xcscheme +++ b/NetNewsWire.xcodeproj/xcshareddata/xcschemes/NetNewsWire.xcscheme @@ -15,7 +15,7 @@ @@ -31,7 +31,7 @@ @@ -69,7 +69,7 @@ @@ -86,7 +86,7 @@ diff --git a/Tests/NetNewsWireTests/ScriptingTests/ScriptingTests.swift b/Tests/NetNewsWireTests/ScriptingTests/ScriptingTests.swift index 663e9b101..e89fb2381 100644 --- a/Tests/NetNewsWireTests/ScriptingTests/ScriptingTests.swift +++ b/Tests/NetNewsWireTests/ScriptingTests/ScriptingTests.swift @@ -81,8 +81,16 @@ class ScriptingTests: AppleScriptXCTestCase { actions and the keystrokes aren't delivered to the app right away, so the ui isn't updated in time for 'current article' to be set. But, breaking them up in this way seems to work. + + July 30, 2019: There's an issue where in order for a script to send keystrokes, + The app has to be allowed to interact with the SystemEvents.app in + System Preferences -> Security & Privacy -> Privacy -> Accessibility + and this premission needs to be renewed every time the app is recompiled unless + the app is codesigned. Until we figure out how to get around this limitation, + this test is disabled. */ - func testCurrentArticleScripts() { + func disabledTestCurrentArticleScripts() { + doIndividualScriptWithExpectation(filename: "uiScriptingTestSetup") doIndividualScriptWithExpectation(filename: "establishMainWindowStartingState") doIndividualScriptWithExpectation(filename: "selectAFeed")