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

Create an app:move command #32368

Closed
wants to merge 1 commit into from
Closed

Create an app:move command #32368

wants to merge 1 commit into from

Conversation

settermjd
Copy link
Contributor

Description

#29807 documents that moving apps from the core to a non-core apps folder manually can cause issues. Given that and the discussion in owncloud-archive/documentation#4276, I decided to start writing an app:move command, to make moving apps from the core apps directory, to a custom non-core apps directory simpler and less messy.

When finished, the command will be able to:

  • List apps that can be moved
  • List any non-core app directories
  • Check that non-core app directories exist
  • Move one or more apps from the core apps directory to a non-core apps directory

The other reason for doing this is to better familiarise myself with ownCloud's internals — something that, for quite some time, I've felt I've been lacking, and that has been hindering me from doing my work better.

Related Issue

Motivation and Context

How Has This Been Tested?

  • ...

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Technical debt
  • Tests

Checklist:

  • Code changes
  • Unit tests added
  • Acceptance tests added
  • Documentation ticket raised:

Open tasks:

  • Backport (if applicable set "backport-request" label and remove when the backport was done)

#29807 documents that moving apps
from the core to a non-core apps folder manually can cause issues. Given
that and the discussion in
owncloud-archive/documentation#4276, I decided to start
writing an app:move command, to make moving apps from the core apps
directory, to a custom non-core apps directory simpler and less messy.

When finished, the command will be able to:

- List apps that can be moved
- List any non-core app directories
- Check that non-core app directories exist
- Move one or more apps from the core apps directory to a non-core apps directory

The other reason for doing this is to better familiarise myself with
ownCloud's internals — something that, for quite some time, I've felt
I've been lacking, and that has been hindering me from doing my work
better.
@tomneedham
Copy link
Contributor

From #29807 I can't actually see that is real issue was discovered... surely we fix that first, or at least understand it before building a tool to work around it?

@mmattel
Copy link
Contributor

mmattel commented Aug 17, 2018

#32048 (Apps: shipped - nonshipped identification mismatch)

* @param OutputInterface $output
* @param array $items
*/
protected function writeNonAppDirectories(InputInterface $input, OutputInterface $output) {
Copy link
Contributor

@mmattel mmattel Aug 17, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would recommend to split that into two functions.

The first one gathers all possible writeable apps_paths path values:
Following return values:
1.) because it is possible that the key apps_paths is not existent which means that there is no alternative apps location, you must return the default path which is /apps.
2.) false or null (to be decided) in case the apps_paths key contains a alternative path but is not writable
3.) all alternative writable paths

The second function prints according the return value the finding.
Based on the three possible cases of function above, the output can and should be differnt so the admin clearly sees what is going on.
a.) /apps means no alternative apps location defined
b.) false or null means apps_paths key found but no writable path set
c.) array of writable paths

You will need function one in any case because when you move you need to know that

@PVince81 PVince81 added this to the backlog milestone Aug 21, 2018
@PVince81
Copy link
Contributor

@cdamken @voroyam has this been reported an issue in known deployment scenarios ?

@DeepDiver1975
Copy link
Member

As discussed in #35777 the master branch will from now on hold the ownCloud 10 codebase.

This PR targetted ownCloud 11 which is postponed to a far distant future.

Because of that I'm closing this PR and kindly ask you to re-submit this PR in a few days.

Thanks a lot for your patience

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants