diff --git a/pkgs/tools/admin/google-cloud-sdk/alpha__init__.py b/pkgs/tools/admin/google-cloud-sdk/alpha__init__.py new file mode 100755 index 000000000000..d120969d8fb8 --- /dev/null +++ b/pkgs/tools/admin/google-cloud-sdk/alpha__init__.py @@ -0,0 +1,23 @@ +# Copyright 2013 Google Inc. All Rights Reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""Auth for the Google Cloud SDK. +""" + +from googlecloudsdk.calliope import base + + +@base.ReleaseTracks(base.ReleaseTrack.ALPHA) +class Alpha(base.Group): + """Alpha versions of gcloud commands.""" diff --git a/pkgs/tools/admin/google-cloud-sdk/beta__init__.py b/pkgs/tools/admin/google-cloud-sdk/beta__init__.py new file mode 100755 index 000000000000..bb52c5a0bc4a --- /dev/null +++ b/pkgs/tools/admin/google-cloud-sdk/beta__init__.py @@ -0,0 +1,23 @@ +# Copyright 2013 Google Inc. All Rights Reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""Auth for the Google Cloud SDK. +""" + +from googlecloudsdk.calliope import base + + +@base.ReleaseTracks(base.ReleaseTrack.BETA) +class Beta(base.Group): + """Beta versions of gcloud commands.""" diff --git a/pkgs/tools/admin/google-cloud-sdk/default.nix b/pkgs/tools/admin/google-cloud-sdk/default.nix index d13bcecb9933..26e63283f8da 100644 --- a/pkgs/tools/admin/google-cloud-sdk/default.nix +++ b/pkgs/tools/admin/google-cloud-sdk/default.nix @@ -26,6 +26,7 @@ stdenv.mkDerivation rec { sha256 = "7aa6094d1f9c87f4c2c4a6bdad6a1113aac5e72ea673e659d9acbb059dfd037e"; }; + buildInputs = [python27 makeWrapper]; phases = [ "installPhase" "fixupPhase" ]; @@ -34,6 +35,12 @@ stdenv.mkDerivation rec { mkdir -p "$out" tar -xzf "$src" -C "$out" google-cloud-sdk + mkdir $out/google-cloud-sdk/lib/surface/alpha + cp ${./alpha__init__.py} $out/google-cloud-sdk/lib/surface/alpha/__init__.py + + mkdir $out/google-cloud-sdk/lib/surface/beta + cp ${./beta__init__.py} $out/google-cloud-sdk/lib/surface/beta/__init__.py + # create wrappers with correct env for program in gcloud bq gsutil git-credential-gcloud.sh; do programPath="$out/google-cloud-sdk/bin/$program"