Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add php docs build script #22432

Merged
merged 3 commits into from
Aug 26, 2020
Merged

Add php docs build script #22432

merged 3 commits into from
Aug 26, 2020

Conversation

juliushaertl
Copy link
Member

@juliushaertl juliushaertl commented Aug 26, 2020

For nextcloud/documentation#1782

Adds a build script to build php api documentation on netlify using phpDocumentor. A preview can be found at https://nextcloud-server.netlify.app/

Signed-off-by: Julius Härtl <jus@bitgrid.net>
@ChristophWurst
Copy link
Member

Adds a build script to build php api documentation on netlify using phpDocumentor. A preview can be found at https://nextcloud-server.netlify.app/

This looks amazing!

@rullzer
Copy link
Member

rullzer commented Aug 26, 2020

@juliushaertl could you make sure that OC things don't get indexed? We don't want people using that ;)

@juliushaertl
Copy link
Member Author

Yep, I'll have another look. Seems mainly caused by invalid @package annotations in lib/public:

ack @package lib/public | grep -v OCP 
lib/public/Share/IProviderFactory.php:31: * @package OC\Share20
lib/public/IGroupManager.php:46: * @package OC\Group
lib/public/IUserManager.php:47: * @package OC\User
lib/public/FullTextSearch/Model/IIndexDocument.php:44: * @package OC\FullTextSearch\Model
lib/public/Files/SimpleFS/InMemoryFile.php:35: * @package OC\Files\SimpleFS

@rullzer
Copy link
Member

rullzer commented Aug 26, 2020

Yep, I'll have another look. Seems mainly caused by invalid @package annotations in lib/public:

ack @package lib/public | grep -v OCP 
lib/public/Share/IProviderFactory.php:31: * @package OC\Share20
lib/public/IGroupManager.php:46: * @package OC\Group
lib/public/IUserManager.php:47: * @package OC\User
lib/public/FullTextSearch/Model/IIndexDocument.php:44: * @package OC\FullTextSearch\Model
lib/public/Files/SimpleFS/InMemoryFile.php:35: * @package OC\Files\SimpleFS

ah then we just fix those :)

@kesselb
Copy link
Contributor

kesselb commented Aug 26, 2020

https://nextcloud-server.netlify.app/packages/ocp-appframeworkanyapplicationmustinheritthiscall

😂 (Nothing wrong with it. I just laughed about the long package name)

Signed-off-by: Julius Härtl <jus@bitgrid.net>
@juliushaertl
Copy link
Member Author

juliushaertl commented Aug 26, 2020

Pushed a fix. As a general thing I think we could just drop all @package declarations since they just are equal to the namespace where they are used.

https://docs.phpdoc.org/latest/references/phpdoc/tags/package.html

The @package tag can be used as a counterpart or supplement to Namespaces. Namespaces provide a functional subdivision of Structural Elements where the @package tag can provide a logical subdivision in which way the elements can be grouped with a different hierarchy.

Since we don't introduce any different structure removing them will make the docs output a lot cleaner with out having duplicated hierarchies.

@ChristophWurst
Copy link
Member

Pushed a fix. As a general thing I think we could just drop all @package declarations since they just are equal to the namespace where they are used.

I think we only have them because phpstorm adds those when you create a new class

@kesselb
Copy link
Contributor

kesselb commented Aug 26, 2020

* @package OCP\APP

Mind to remove?

image

To fix App and APP.

Signed-off-by: Julius Härtl <jus@bitgrid.net>
@juliushaertl
Copy link
Member Author

Pushed a commit to remove all the @package annotations in lib/public now. Feels a lot cleaner not having any in the docs now.

@faily-bot
Copy link

faily-bot bot commented Aug 26, 2020

🤖 beep boop beep 🤖

Here are the logs for the failed build:

Status of 32344: failure

acceptance-app-files

  • tests/acceptance/features/app-files.feature:262
Show full log
  Scenario: unmarking a file as favorite causes the file list to be sorted again                          # /drone/src/tests/acceptance/features/app-files.feature:262
    Given I am logged in                                                                                  # LoginPageContext::iAmLoggedIn()
    And I create a new folder named "A name alphabetically lower than welcome.txt"                        # FileListContext::iCreateANewFolderNamed()
    And I see that "A name alphabetically lower than welcome.txt" precedes "welcome.txt" in the file list # FileListContext::iSeeThatPrecedesInTheFileList()
    And I close the details view                                                                          # FilesAppContext::iCloseTheDetailsView()
    And I see that the details view is closed                                                             # FilesAppContext::iSeeThatTheDetailsViewIsClosed()
    And I mark "welcome.txt" as favorite                                                                  # FileListContext::iMarkAsFavorite()
    And I see that "welcome.txt" is marked as favorite                                                    # FileListContext::iSeeThatIsMarkedAsFavorite()
    And I see that "welcome.txt" precedes "A name alphabetically lower than welcome.txt" in the file list # FileListContext::iSeeThatPrecedesInTheFileList()
    When I unmark "welcome.txt" as favorite                                                               # FileListContext::iUnmarkAsFavorite()
    Then I see that "welcome.txt" is not marked as favorite                                               # FileListContext::iSeeThatIsNotMarkedAsFavorite()
      Not favorited state icon for file welcome.txt in file list could not be found after 100 seconds (NoSuchElementException)
    And I see that "A name alphabetically lower than welcome.txt" precedes "welcome.txt" in the file list # FileListContext::iSeeThatPrecedesInTheFileList()

@juliushaertl juliushaertl added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Aug 26, 2020
@rullzer rullzer merged commit b5e9f7e into master Aug 26, 2020
@rullzer rullzer deleted the enh/phpdoc branch August 26, 2020 19:18
@rullzer rullzer mentioned this pull request Aug 27, 2020
19 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4. to release Ready to be released and/or waiting for tests to finish
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants