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

feat: composer cleanup task #1877

Merged
merged 15 commits into from
Jul 23, 2020
Merged

feat: composer cleanup task #1877

merged 15 commits into from
Jul 23, 2020

Conversation

bshaffer
Copy link
Contributor

@bshaffer bshaffer commented Jul 10, 2020

An attempt to solve #1867 for those who have filesize limits:

In your composer.json:

{
    "require": {
        "google/apiclient": "^2.7"
    },
    "extra": {
        "google/apiclient-services": [
            "YouTube"
        ]
    },
    "scripts": {
        "post-update-cmd": "Google_Task_Composer::cleanup"
    }
}

This will remove all services but YouTube. If a non-existent service is supplied, an exception is thrown.

@bshaffer bshaffer requested a review from jdpedrie July 10, 2020 19:02
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Jul 10, 2020
Copy link
Contributor

@jdpedrie jdpedrie left a comment

Choose a reason for hiding this comment

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

Can we include this in the README too?

tests/Google/Task/ComposerTest.php Outdated Show resolved Hide resolved
@jdpedrie
Copy link
Contributor

@bshaffer what's the latest with this?

Copy link
Contributor

@dwsupplee dwsupplee left a comment

Choose a reason for hiding this comment

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

This is really clever, I like it 👍

tests/Google/Task/ComposerTest.php Outdated Show resolved Hide resolved
Copy link
Contributor

@jdpedrie jdpedrie left a comment

Choose a reason for hiding this comment

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

All it needs is usage instructions in the README. :)

@bshaffer
Copy link
Contributor Author

bshaffer commented Jul 23, 2020

@jdpedrie @dwsupplee the README has been updated with instructions. Please take a look as there is an ugly caveat involved.

{
$composerJson = json_encode([
'require' => [
'google/apiclient' => 'dev-add-composer-cleanup'
Copy link
Contributor Author

Choose a reason for hiding this comment

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

We will need to change this before tagging a new version!

@bshaffer bshaffer changed the title feat(DO NOT MERGE): Composer cleanup task feat: composer cleanup task Jul 23, 2020
@bshaffer bshaffer merged commit 7b57cd7 into master Jul 23, 2020
@bshaffer bshaffer deleted the add-composer-cleanup branch July 23, 2020 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants