should this depend on the python3 module (in the yaml)?
On Mon, Aug 17, 2015 at 6:18 AM, Jonathan Cave <email address hidden>
wrote:
> Jonathan Cave has proposed merging
> lp:~jocave/snapcraft/plainbox-provider-plugin into lp:snapcraft.
>
> Requested reviews:
> Snappy Developers (snappy-dev)
>
> For more details, see:
>
> https://code.launchpad.net/~jocave/snapcraft/plainbox-provider-plugin/+merge/268221
>
> Adds a plugin for building Plainbox Providers in to snaps.
>
> Plainbox providers contain test definitions to be used with the Plainbox
> test
> runner itself.
>
> This plugin takes the a provider from the source location defined and runs
> the
> appropriate commands to
> 1. run the provider build step so any binaries are created
> 2. run the provider install step to stage the provider in the desired
> layout
>
> --
> Your team Snappy Developers is requested to review the proposed merge of
> lp:~jocave/snapcraft/plainbox-provider-plugin into lp:snapcraft.
>
> Launchpad-Message-Rationale: Reviewer @snappy-dev
> Launchpad-Notification-Type: code-review
> Launchpad-Branch: ~jocave/snapcraft/plainbox-provider-plugin
> Launchpad-Project: snapcraft
>
> === added file 'plugins/plainbox-provider.yaml'
> --- plugins/plainbox-provider.yaml 1970-01-01 00:00:00 +0000
> +++ plugins/plainbox-provider.yaml 2015-08-17 13:17:58 +0000
> @@ -0,0 +1,4 @@
> +module: plainbox_provider
> +options:
> + source:
> + required: true
>
> === added file 'snapcraft/plugins/plainbox_provider.py'
> --- snapcraft/plugins/plainbox_provider.py 1970-01-01 00:00:00 +0000
> +++ snapcraft/plugins/plainbox_provider.py 2015-08-17 13:17:58 +0000
> @@ -0,0 +1,34 @@
> +# -*- Mode:Python; indent-tabs-mode:nil; tab-width:4 -*-
> +#
> +# Copyright (C) 2015 Canonical Ltd
> +#
> +# This program is free software: you can redistribute it and/or modify
> +# it under the terms of the GNU General Public License version 3 as
> +# published by the Free Software Foundation.
> +#
> +# This program is distributed in the hope that it will be useful,
> +# but WITHOUT ANY WARRANTY; without even the implied warranty of
> +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> +# GNU General Public License for more details.
> +#
> +# You should have received a copy of the GNU General Public License
> +# along with this program. If not, see <http://www.gnu.org/licenses/>.
> +
> +import snapcraft
> +
> +
> +class PlainboxProviderPlugin(snapcraft.BasePlugin):
> +
> + # note that we don't need to setup env(), python figures it out
> + # see python3.py for more details
> +
> + def pull(self):
> + return self.handle_source_options()
> +
> + def build(self):
> + return self.run(["python3", "manage.py", "build"])
> +
> + def stage(self):
> + return self.run(
> + ["python3", "manage.py", "install", "--layout=snappy",
> + "--root=%s" % self.installdir])
>
>
>
should this depend on the python3 module (in the yaml)?
On Mon, Aug 17, 2015 at 6:18 AM, Jonathan Cave <email address hidden>
wrote:
> Jonathan Cave has proposed merging /code.launchpad .net/~jocave/ snapcraft/ plainbox- provider- plugin/ +merge/ 268221 Message- Rationale: Reviewer @snappy-dev Notification- Type: code-review snapcraft/ plainbox- provider- plugin plainbox- provider. yaml' plainbox- provider. yaml 1970-01-01 00:00:00 +0000 plainbox- provider. yaml 2015-08-17 13:17:58 +0000 plugins/ plainbox_ provider. py' plugins/ plainbox_ provider. py 1970-01-01 00:00:00 +0000 plugins/ plainbox_ provider. py 2015-08-17 13:17:58 +0000 tabs-mode: nil; tab-width:4 -*- www.gnu. org/licenses/>. rPlugin( snapcraft. BasePlugin) : source_ options( ) ["python3" , "manage.py", "build"])
> lp:~jocave/snapcraft/plainbox-provider-plugin into lp:snapcraft.
>
> Requested reviews:
> Snappy Developers (snappy-dev)
>
> For more details, see:
>
> https:/
>
> Adds a plugin for building Plainbox Providers in to snaps.
>
> Plainbox providers contain test definitions to be used with the Plainbox
> test
> runner itself.
>
> This plugin takes the a provider from the source location defined and runs
> the
> appropriate commands to
> 1. run the provider build step so any binaries are created
> 2. run the provider install step to stage the provider in the desired
> layout
>
> --
> Your team Snappy Developers is requested to review the proposed merge of
> lp:~jocave/snapcraft/plainbox-provider-plugin into lp:snapcraft.
>
> Launchpad-
> Launchpad-
> Launchpad-Branch: ~jocave/
> Launchpad-Project: snapcraft
>
> === added file 'plugins/
> --- plugins/
> +++ plugins/
> @@ -0,0 +1,4 @@
> +module: plainbox_provider
> +options:
> + source:
> + required: true
>
> === added file 'snapcraft/
> --- snapcraft/
> +++ snapcraft/
> @@ -0,0 +1,34 @@
> +# -*- Mode:Python; indent-
> +#
> +# Copyright (C) 2015 Canonical Ltd
> +#
> +# This program is free software: you can redistribute it and/or modify
> +# it under the terms of the GNU General Public License version 3 as
> +# published by the Free Software Foundation.
> +#
> +# This program is distributed in the hope that it will be useful,
> +# but WITHOUT ANY WARRANTY; without even the implied warranty of
> +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> +# GNU General Public License for more details.
> +#
> +# You should have received a copy of the GNU General Public License
> +# along with this program. If not, see <http://
> +
> +import snapcraft
> +
> +
> +class PlainboxProvide
> +
> + # note that we don't need to setup env(), python figures it out
> + # see python3.py for more details
> +
> + def pull(self):
> + return self.handle_
> +
> + def build(self):
> + return self.run(
> +
> + def stage(self):
> + return self.run(
> + ["python3", "manage.py", "install", "--layout=snappy",
> + "--root=%s" % self.installdir])
>
>
>