Skip to content

Commit

Permalink
feat: remove NETLIFY_EXPERIMENTAL_BUILD_GO_SOURCE (#3504)
Browse files Browse the repository at this point in the history
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
  • Loading branch information
eduardoboucas and kodiakhq[bot] authored Oct 15, 2021
1 parent 0eea04d commit f9cd6ba
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions src/commands/functions/create.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,14 @@ const { readRepoURL, validateRepoURL } = require('../../utils/read-repo-url')

const templatesDir = path.resolve(__dirname, '../../functions-templates')

const showGoTemplates = process.env.NETLIFY_EXPERIMENTAL_BUILD_GO_SOURCE === 'true'
const showRustTemplates = process.env.NETLIFY_EXPERIMENTAL_BUILD_RUST_SOURCE === 'true'

// Ensure that there's a sub-directory in `src/functions-templates` named after
// each `value` property in this list.
const languages = [
{ name: 'JavaScript', value: 'javascript' },
{ name: 'TypeScript', value: 'typescript' },
showGoTemplates && { name: 'Go', value: 'go' },
{ name: 'Go', value: 'go' },
showRustTemplates && { name: 'Rust', value: 'rust' },
]

Expand Down
2 changes: 1 addition & 1 deletion src/lib/functions/registry.js
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ class FunctionsRegistry {

const functions = await this.listFunctions(directories, {
featureFlags: {
buildGoSource: env.NETLIFY_EXPERIMENTAL_BUILD_GO_SOURCE === 'true',
buildGoSource: true,
buildRustSource: env.NETLIFY_EXPERIMENTAL_BUILD_RUST_SOURCE === 'true',
},
})
Expand Down
2 changes: 1 addition & 1 deletion tests/serving-functions-go.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ test('Updates a Go function when a file is modified', async (t) => {
await withDevServer(
{
cwd: builder.directory,
env: { ...execaMock, NETLIFY_EXPERIMENTAL_BUILD_GO_SOURCE: 'true' },
env: execaMock,
},
async ({ port, outputBuffer }) => {
await tryAndLogOutput(async () => {
Expand Down

1 comment on commit f9cd6ba

@github-actions
Copy link

Choose a reason for hiding this comment

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

📊 Benchmark results

Package size: 357 MB

Please sign in to comment.