Skip to content

Commit

Permalink
feat: add index folder. (#17)
Browse files Browse the repository at this point in the history
  • Loading branch information
dirien authored Dec 19, 2022
1 parent 3ad883b commit 1a51f3a
Show file tree
Hide file tree
Showing 31 changed files with 2,671 additions and 218 deletions.
2 changes: 1 addition & 1 deletion examples/purrl-go/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package main

import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumiverse/pulumi-purrl/sdk/go/purrl/purrl"
"github.com/pulumiverse/pulumi-purrl/sdk/go/purrl"
)

func main() {
Expand Down
2 changes: 2 additions & 0 deletions examples/purrl-ts/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/bin/
/node_modules/
3 changes: 3 additions & 0 deletions examples/purrl-ts/Pulumi.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
name: purrl-ts
description: A minimal TypeScript Pulumi program
runtime: nodejs
1 change: 1 addition & 0 deletions examples/purrl-ts/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
import * as pulumi from "@pulumi/pulumi";
2,565 changes: 2,565 additions & 0 deletions examples/purrl-ts/package-lock.json

Large diffs are not rendered by default.

11 changes: 11 additions & 0 deletions examples/purrl-ts/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"name": "purrl-ts",
"main": "index.ts",
"devDependencies": {
"@types/node": "^18"
},
"dependencies": {
"@pulumi/pulumi": "^3.49.0",
"@pulumiverse/purrl": "^0.2.2"
}
}
18 changes: 18 additions & 0 deletions examples/purrl-ts/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"compilerOptions": {
"strict": true,
"outDir": "bin",
"target": "es2016",
"module": "commonjs",
"moduleResolution": "node",
"sourceMap": true,
"experimentalDecorators": true,
"pretty": true,
"noFallthroughCasesInSwitch": true,
"noImplicitReturns": true,
"forceConsistentCasingInFileNames": true
},
"files": [
"index.ts"
]
}
2 changes: 1 addition & 1 deletion provider/cmd/pulumi-gen-purrl/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ import (
"encoding/json"
"flag"
"fmt"
pucurl "github.com/pulumiverse/pulumi-purrl/provider/pkg/provider"
"os"

pucurl "github.com/pulumiverse/pulumi-purrl/provider/pkg/provider"
providerVersion "github.com/pulumiverse/pulumi-purrl/provider/pkg/version"
)

Expand Down
4 changes: 2 additions & 2 deletions provider/cmd/pulumi-resource-purrl/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,20 @@ package main

import (
"fmt"
"github.com/pulumiverse/pulumi-purrl/provider/pkg/provider"
"os"
"strings"

p "github.com/pulumi/pulumi-go-provider"

purrl "github.com/pulumiverse/pulumi-purrl/provider/pkg/provider"
"github.com/pulumiverse/pulumi-purrl/provider/pkg/version"
)

func main() {
version := strings.TrimPrefix(version.Version, "v")

// This method defines the provider implemented in this repository.
purrlProvider := purrl.NewProvider()
purrlProvider := provider.NewProvider()

// This method starts serving requests using the pucurl provider.
err := p.RunProvider("purrl", version, purrlProvider)
Expand Down
2 changes: 1 addition & 1 deletion provider/cmd/pulumi-resource-purrl/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"publisher": "Pulumiverse",
"repository": "https://github.com/pulumiverse/pulumi-purrl",
"resources": {
"purrl:purrl:Purrl": {
"purrl:index:Purrl": {
"description": "A Pulumi provider for making API calls",
"inputProperties": {
"body": {
Expand Down
6 changes: 5 additions & 1 deletion provider/pkg/provider/provider.go
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
package provider

import (
"github.com/pulumi/pulumi/sdk/v3/go/common/tokens"
"github.com/pulumiverse/pulumi-purrl/provider/pkg/provider/purrl"
"strings"

"github.com/blang/semver"
p "github.com/pulumi/pulumi-go-provider"
"github.com/pulumi/pulumi-go-provider/infer"
"github.com/pulumi/pulumi-go-provider/integration"
"github.com/pulumi/pulumi-go-provider/middleware/schema"
"github.com/pulumiverse/pulumi-purrl/provider/pkg/provider/purrl"
)

// NewProvider This provider uses the `pulumi-go-provider` library to produce a code-first provider definition.
Expand Down Expand Up @@ -80,6 +81,9 @@ func NewProvider() p.Provider {
purrl.PurrlOutputs,
](),
},
ModuleMap: map[tokens.ModuleName]tokens.ModuleName{
"purrl": "index",
},
})
}

Expand Down
8 changes: 4 additions & 4 deletions sdk/dotnet/Purrl/Purrl.cs → sdk/dotnet/Purrl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@
using Pulumi.Serialization;
using Pulumi;

namespace Pulumiverse.Purrl.Purrl
namespace Pulumiverse.Purrl
{
/// <summary>
/// A Pulumi provider for making API calls
/// </summary>
[PurrlResourceType("purrl:purrl:Purrl")]
[PurrlResourceType("purrl:index:Purrl")]
public partial class Purrl : global::Pulumi.CustomResource
{
/// <summary>
Expand Down Expand Up @@ -103,12 +103,12 @@ public partial class Purrl : global::Pulumi.CustomResource
/// <param name="args">The arguments used to populate this resource's properties</param>
/// <param name="options">A bag of options that control this resource's behavior</param>
public Purrl(string name, PurrlArgs args, CustomResourceOptions? options = null)
: base("purrl:purrl:Purrl", name, args ?? new PurrlArgs(), MakeResourceOptions(options, ""))
: base("purrl:index:Purrl", name, args ?? new PurrlArgs(), MakeResourceOptions(options, ""))
{
}

private Purrl(string name, Input<string> id, CustomResourceOptions? options = null)
: base("purrl:purrl:Purrl", name, null, MakeResourceOptions(options, id))
: base("purrl:index:Purrl", name, null, MakeResourceOptions(options, id))
{
}

Expand Down
1 change: 0 additions & 1 deletion sdk/dotnet/Purrl/README.md

This file was deleted.

25 changes: 25 additions & 0 deletions sdk/go/purrl/init.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions sdk/go/purrl/purrl/purrl.go → sdk/go/purrl/purrl.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

44 changes: 0 additions & 44 deletions sdk/go/purrl/purrl/init.go

This file was deleted.

101 changes: 0 additions & 101 deletions sdk/go/purrl/purrl/pulumiUtilities.go

This file was deleted.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified sdk/java/build/libs/com.pulumiverse.purrl.jar
Binary file not shown.
Binary file modified sdk/java/build/tmp/compileJava/previous-compilation-data.bin
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
// *** WARNING: this file was generated by pulumi. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumiverse.purrl.purrl;
package com.pulumiverse.purrl;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import com.pulumiverse.purrl.PurrlArgs;
import com.pulumiverse.purrl.Utilities;
import com.pulumiverse.purrl.purrl.PurrlArgs;
import java.lang.String;
import java.util.List;
import java.util.Map;
Expand All @@ -19,7 +19,7 @@
* A Pulumi provider for making API calls
*
*/
@ResourceType(type="purrl:purrl:Purrl")
@ResourceType(type="purrl:index:Purrl")
public class Purrl extends com.pulumi.resources.CustomResource {
/**
* The body of the request.
Expand Down Expand Up @@ -226,11 +226,11 @@ public Purrl(String name, PurrlArgs args) {
* @param options A bag of options that control this resource's behavior.
*/
public Purrl(String name, PurrlArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
super("purrl:purrl:Purrl", name, args == null ? PurrlArgs.Empty : args, makeResourceOptions(options, Codegen.empty()));
super("purrl:index:Purrl", name, args == null ? PurrlArgs.Empty : args, makeResourceOptions(options, Codegen.empty()));
}

private Purrl(String name, Output<String> id, @Nullable com.pulumi.resources.CustomResourceOptions options) {
super("purrl:purrl:Purrl", name, null, makeResourceOptions(options, id));
super("purrl:index:Purrl", name, null, makeResourceOptions(options, id));
}

private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output<String> id) {
Expand Down
Loading

0 comments on commit 1a51f3a

Please sign in to comment.