Граф коммитов

264 Коммитов

Автор SHA1 Сообщение Дата
Eric Jizba af740b287c
Default nightly tests to v3 instead of v2 🧪 (#1915) 2020-02-21 11:14:05 -08:00
Eric Jizba 66b302d996
Fix C# nightly test 🌃🧪 (#1903) 2020-02-20 16:59:45 -08:00
Eric Jizba 1f557b7a53
Add a few more templates to verified category (#1910) 2020-02-20 16:52:07 -08:00
Eric Jizba ad35ea2a4a
Add IoT template to "verified" for C# (#1902) 2020-02-20 16:44:38 -08:00
Eric Jizba 270d46c4f3
Show local project for C#/Java (#1883) 2020-02-14 13:21:34 -08:00
Eric Jizba afd650bc89
Prompt for runtime before OS (#1890) 2020-02-13 16:54:12 -08:00
Eric Jizba 67c8ebc6b8
Remove binding tree items (#1875) 2020-02-07 11:04:19 -08:00
Eric Jizba 6fc3c2ef00
Use "func: extensions install" if extensions.csproj exists (#1861) 2020-02-05 16:02:50 -08:00
Eric Jizba 4441c34f45
Update some dependencies (#1846) 2020-01-29 09:20:41 -08:00
Eric Jizba 8a8daca8e6
Use vscode.env.shell when picking python venv stuff (#1814) 2020-01-17 15:44:42 -08:00
Eric Jizba aeea904941
Simplify validation of language/version when deploying (#1812) 2020-01-17 14:53:45 -08:00
Eric Jizba e42d7fbb15
Remove "experimental" languages (#1799) 2020-01-14 12:12:25 -08:00
Eric Jizba c349dde7bb
Disable PowerShell nightly test 🌃🧪 (#1784) 2020-01-14 09:16:39 -08:00
Eric Jizba 20786d597d
Prompt user to pick python version when creating a project 🐍 (#1670) 2019-11-11 08:49:48 -08:00
Eric Jizba 326f38a2e9
Get rid of platform 🍎🏠🐧 constants 🗑 (#1671) 2019-11-08 15:52:27 -08:00
Eric Jizba 93a8ebe455
Clean up project tests 🧹 (#1668)
Some highlights:
- Split `createNewProject.test.ts` into separate files
- Got rid of about 100 lines of "duplicate" code in `initProjectForVSCode.test.ts`
- More precise testing of `settings.json`
2019-11-08 09:18:53 -08:00
Eric Jizba 4242820e6e
Fix python nightly test (#1665) 2019-11-06 14:08:01 -08:00
Eric Jizba 6aac92a8e8
Update "Create New Project" tests 🧪 to work with v3 (#1663) 2019-11-05 15:50:11 -08:00
Eric Jizba 482ac9221b
Better cleaning 🧹 of test workspace (#1646) 2019-11-01 11:45:39 -07:00
Eric Jizba 156a9a15f8
Add v3 to "Create Function" tests (#1638) 2019-10-31 16:31:05 -07:00
Eric Jizba f641c1166f
Support runtime versions 🏃🏻‍♂️ (#1627) 2019-10-30 17:36:33 -07:00
Eric Jizba e2a6f4932b
Workaround for C# v3 template id (#1628) 2019-10-30 16:35:07 -07:00
Eric Jizba 9d9a73014c
Initial support for Azure Functions v3 Preview 🔍👀 (#1606) 2019-10-24 16:16:07 -07:00
Eric Jizba 9421bf7210
Add support for file tree items 🗄🌲 (#1592) 2019-10-17 16:22:42 -07:00
Eric Jizba 3dc4b07a31
Add basic test for "Add Binding" 🧪 (#1587) 2019-10-17 13:30:44 -07:00
Eric Jizba 56fc0ede51
Fix test failures (#1569) 2019-10-09 17:26:21 -07:00
Eric Jizba 76ddaab43a
Fix python nightly test (#1555) 2019-10-08 11:40:47 -07:00
Eric Jizba b3b8e69955
Add nuget versioning logic for getting bundle templates (#1545) 2019-10-07 13:53:05 -07:00
Eric Jizba 492a046950
Get templates from bundle feed (#1540) 2019-10-07 13:37:01 -07:00
Eric Jizba dbabf54950
Vary location and auth level for nightly tests (#1550) 2019-10-04 15:24:05 -07:00
Eric Jizba feee4e9ade
Default Python to remote build (#1549) 2019-10-04 15:07:12 -07:00
Eric Jizba ea24dbb4bb
Actually support cached/backup/verified templates for Java (#1525) 2019-09-30 14:54:32 -07:00
Eric Jizba e6536a5e61 Better error handling/loading of templates (#1509) 2019-09-25 15:07:55 -07:00
Eric Jizba b9114b181f
Add python test (#1482) 2019-09-25 14:13:35 -07:00
Eric Jizba 439ea64a6e
Clean up request code (#1493) 2019-09-18 17:09:43 -07:00
Eric Jizba 5d9891c914
Update dependencies (#1470) 2019-08-29 08:31:03 -07:00
v-wuzhai fe62f3a7b6
Add test case to deploy powershell project (#1440)
* Add test case to deploy powershell project

* Update code according to the comments
2019-08-20 19:39:13 -07:00
Nathan 4ea0843098
Fix nightly tests (#1447)
* Fix nightly tests
2019-08-16 11:40:14 -07:00
Eric Jizba 7b72289246
Change python default back to local build (#1442) 2019-08-13 13:44:12 -07:00
Eric Jizba 0ed34608ef
Add support for server-side build for Linux Function Apps (#1420) 2019-08-07 08:35:22 -07:00
Eric Jizba 6d6859922e
Clean up nightly tests (#1414) 2019-08-01 08:36:56 -07:00
Eric Jizba efe1212057
Enable project tree view (#1396) 2019-07-30 13:54:28 -07:00
Eric Jizba 4aebf7004f
Bump shared packages (#1405) 2019-07-29 14:52:22 -07:00
Eric Jizba 55b5e652ff
Add a few more prompts to basic create (#1400) 2019-07-25 08:27:50 -07:00
Eric Jizba 892aeef7e3
Make advanced creation more discoverable (#1391) 2019-07-22 15:20:48 -07:00
Eric Jizba d081d14306
Update ui package (#1382) 2019-07-18 08:32:42 -07:00
Eric Jizba 8ab3e2a4cc
Change default python venv name (#1373) 2019-07-17 12:41:56 -05:00
v-wuzhai 4ae2b4fe87
Add tests for deploying CSharp and JavaScript projects (#1190)
* Add tests for deploying CSharp and JavaScript projects

* Modify the code according to FTE's comments

* Solve the file conflict in the package.json

* Modify the code according to FTE's comments

* Modify file configuration information in package.json

* Modify the code according to FTE's comments

* Modify the code according to FTE's comments

* Modify the code according to FTE's comments

* Adjust the code format

* Update the path to match docker repo

* Update code according to the comments

* Update code according to the comments

* Update code according to the comments

* Update code according to the comments
2019-07-01 19:45:00 -07:00
Eric Jizba 2577a97566
Update to ui package v0.25.0 for actionContext changes (#1286)
See https://github.com/microsoft/vscode-azuretools/pull/503 for more info
2019-05-20 22:26:12 +00:00
Eric Jizba 2dff550e34
Move to latest tree that's friendlier to non-Azure scenarios (#1273) 2019-05-15 22:49:45 +00:00
Eric Jizba ac4049a1d1
Revert workaround for TestOutputChannel (#1263) 2019-05-07 17:37:08 +00:00
Eric Jizba a0667e1cd2
Remove feature flag for PowerShell (#1229) 2019-04-26 13:47:57 -07:00
Eric Jizba 565491de06
Add package.json to JavaScript projects (#1231) 2019-04-26 12:13:47 -07:00
Eric Jizba 680582b121
Allow users to select dedicated plan in advanced creation (#1221)
Also move java test to long-running that was having timeout issues
2019-04-25 17:29:58 -07:00
Eric Jizba 891f233dbf Improve "Create Function" tests
1. Actually verify the settings passed in
1. Don't use "vscode.command.executeCommand" becuase that swallows exceptions
1. Validate that there is a test for every "Verified" template
2019-04-24 14:48:54 -07:00
Eric Jizba 23d4ea6214 Clean up naming of function/trigger/binding
And refactor a little bit to reduce copied code for binding settings
2019-04-24 14:48:54 -07:00
Eric Jizba 167968df85 Add Event Hub triggers to verified category 2019-04-24 14:48:54 -07:00
Eric Jizba 2c247b9b9d Consolidate logic related to function artifacts into "funcConfig" folder
Aka logic related to "function.json", "local.settings.json", "host.json", etc.
2019-04-22 15:59:45 -07:00
Eric Jizba c076c1d502 Rename inBinding to triggerBinding 2019-04-22 15:59:45 -07:00
Eric Jizba 783cc3e89d Basic support for extension bundles 2019-04-22 15:59:45 -07:00
Eric Jizba 99f6ea3928
Add durable templates to verified category in JS & TS (#1210)
Also split the current "Template Count" test into multiple tests. Previously the test only reported the first failure - now I can see individual failures per language/runtime/source.
2019-04-22 14:53:16 -07:00
Eric Jizba 970b75e242
Make "Init for VS Code" less destructive (#1196)
As opposed to overwriting the "tasks.json" and "launch.json" files if they already exist, we will just add our config to those files. I think this is especially necessary when users have their Functions project in a sub directory because that means they could have debug configs for other projects in other sub directories.
2019-04-19 13:32:07 -07:00
Eric Jizba cf7f818d75
Include more PowerShell verified templates (#1197) 2019-04-19 10:56:49 -07:00
Eric Jizba 802c350b19 Refactor verifyVSCodeConfig into separate files
And move ProjectSettings.ts into the same folder
2019-04-12 09:34:08 -07:00
Eric Jizba 3947e878f4 Add bindings wizard
And preview support for local project tree
2019-04-11 13:57:58 -07:00
Francisco Gamino c9380d3c8c Add support in project creation to enable Managed Dependencies for PowerShell. (#1158) 2019-04-11 13:57:01 -07:00
v-wuzhai 7daf4e8331 Add start/stop/restart/delete/create nightly tests (#1128) 2019-04-11 13:50:08 -07:00
Eric Jizba 92fc746c17
Verify language worker runtime on deploy (#1141) 2019-04-09 16:24:14 -07:00
Eric Jizba dbad338d2d
Prep for 0.16.0 release (#1133) 2019-03-28 09:24:25 -07:00
Eric Jizba 94ccb32c76
"Basic" create function app (#1122)
Automatically creates storage account/resource group without prompting the user.
2019-03-26 16:48:28 -07:00
Eric Jizba 2bf329933c
Revamp new project experience (#1119)
Allow users to create a function right after creating a project
Allow projects in subdirectories
2019-03-26 16:14:53 -07:00
Eric Jizba 1b85e77335
Use localized strings when creating functions (#1100) 2019-03-21 16:12:15 -07:00
Eric Jizba ec9b71adbd
Use wizard for create function (#1096) 2019-03-19 15:48:54 -07:00
Eric Jizba 78662d41a1
Update to new UI package with back button in wizard (#1084) 2019-03-14 14:33:15 -07:00
Tyler James Leonhardt 0c90dbd7cc Initial PowerShell on Functions v2 Support (#1075) 2019-03-12 13:51:42 -07:00
Eric Jizba 459678d3e8
Run createFunction tests against v2 instead of v1 (#1080) 2019-03-11 16:45:15 -07:00
Eric Jizba 2d61cea01c
Add new project support for F# (#1042)
With this project, users can debug and deploy. Biggest piece missing is creating a trigger - ultimately we'll have to wait for https://github.com/Azure/azure-functions-templates/issues/627. Because of that, I'm not showing "F#" in the prompt to create a project. User has to set "azureFunctions.projectLanguage" in user settings to "F#" _before_ creating a project to access this feature.
2019-02-27 12:13:21 -08:00
Eric Jizba 9deb8d5088
Consolidate project test code into validateProject.ts (#1043)
I found that project tests were spotty in their coverage and decided to clean up/consolidate. Now, `createNewProject.test.ts` and `initProjectForVSCode.test.ts` share a lot more logic/validation. This makes sense because ideally users end up with the same project no matter if they create it from our extension or if they create it outside of VS Code.

Also just includes more validation like checking "preDeployTask"/"deploySubpath" and more expected paths.
2019-02-27 11:06:46 -08:00
Eric Jizba 881d05297d
Add TypeScript templates to "verified" category (#1020)
- Also update backup templates
- Also also fix tests
    - One error that happens on nightly tests on mac
    - One error that intermittently happens on windows
2019-02-22 17:02:13 -08:00
Eric Jizba 8a26689da4
Add Event Grid trigger and clean up storage/cosmos triggers (#1010) 2019-02-21 11:58:10 -08:00
Eric Jizba a8238d1484
Workaround for tests on mac (#1009)
Ever since a few weeks ago (probably since webpack commit), tests are not running on mac (locally or in Azure Dev Ops). I couldn't figure out a root cause fix, but copying the file to this repo works for now.
2019-02-20 13:29:23 -08:00
Eric Jizba 03274e2bbe
Add TypeScript support (#994) 2019-02-15 16:24:33 -08:00
Eric Jizba 1288b14de3
Post 0.14.0 release (#988)
1. Bump to next alpha
1. npm update
1. Change recommended tslint extension since old one is deprecated
2019-02-12 11:28:49 -08:00
Eric Jizba 9b9549bd1a
Fix and consolidate venvUtils for all terminals/OS's (#978)
I ran into two bugs while testing the release candidate:
1. The tasks.json we generate is meant to work if someone pushes their project to GitHub and clones it on a different OS. That wasn't the case for our "pipInstall" task because it always used the path separator from the _original_ OS
1. Windows users with their terminal set to bash would fail to debug

In order to fix, I ended up doing quite a bit of refactoring of venvUtils and added several tests to cover all the weird edge cases. Here's the list of terminals: https://code.visualstudio.com/docs/editor/integrated-terminal#_configuration

I also removed the logic to install "pylint" by default. It's just another command that could fail and it slows down project creation. We originally did it because the Python extension was super annoying and prompted you to install pylint every time, but now they at least have a "Don't show again" button. Fixes #814
2019-02-08 14:36:12 -08:00
Eric Jizba 576955cf9e
Increase unit test timeout and clean up folder only at the end (#970)
Unit tests have been really flakey lately, especially on windows, and I don't know why. This PR does a few things to mitigate that:
1. Increase the timeout to 20 seconds for everything
1. Clean up the root test folder at the end instead of cleaning intermediary folders along the way
2019-02-06 16:39:04 -08:00
Eric Jizba afcf38b081
Use "vscode-azureextensionui" from bundle to fix nightly tests (#966) 2019-02-06 13:26:53 -08:00
Eric Jizba fe87e68d66
Improve startup performance with webpack (#947) 2019-02-01 09:54:33 -08:00
Eric Jizba 6564ffa33f
Improve tests (#937)
I was having problems with tests when I tried to run them against Insiders for this PR: https://github.com/Microsoft/vscode-azurefunctions/pull/936 These are just a few quality of life improvements that came out of that.
1. Use `mocha-multi-reporters` like stephen's done in other repos
1. Set `ext.ui` immediately. In some cases this will report "Unexpected call to showWarningMessage..." instead of a timeout
1. Added `runWithSetting` so that I had more control on when settings are used in tests. For example, if the `dispose` method of `FunctionTesterBase` failed at `fse.remove` these weren't getting set back
2019-01-31 12:01:28 -08:00
Eric Jizba 29f1988ab9
Fix nightly test (#915)
Nightly tests are failing with this error:
> Error: Did not find quick pick item matching '$(plus) Create new storage account'. Placeholder: 'Select a runtime for your new app.'

We now prompt for runtime if they don't have the project language set, which broke the test. I think it's more common to have the language set, so I went with that scenario to fix.
2019-01-18 15:38:36 -08:00
Eric Jizba 970dd284a4
Disable failing nightly test on Linux (#911) 2019-01-14 14:02:07 -08:00
Eric Jizba 923b5261e5
Enable python project test (#809) 2018-11-15 13:41:15 -08:00
Eric Jizba 479b2fa7dc
Fix template source logic for C# tests (#787)
So I realized that the C# tests weren't actually running tests based on the different template sources since they overwrite the nuget package in the same location. The key fix was to change the location from:
```
path.join('resources', 'dotnetTemplates')
```
to
```
path.join('resources', 'dotnetTemplates', ext.templateSource || '')
```

The rest of the changes are based on that and a little bit of refactor. There should be no functional changes.
2018-11-06 11:19:14 -08:00
Eric Jizba 2b3d51a0d6
Refactor project code (#786) 2018-11-06 10:57:17 -08:00
Eric Jizba b61db77409
Switch from TravisCI to Azure Pipelines (#767) 2018-10-31 12:17:30 -07:00
Eric Jizba 80142b102e
A few engineering improvements (#762)
1. Update typescript version
1. Update tslint version
    1. One of my favorite new rules is "no-implicit-dependencies" which makes sure you have a dependency listed in "package.json" if you're using it. A month-ish ago we had a problem where the storage package was listed as a devDependency instead of a dependency and this rule would've prevented that
1. Update to next alpha
1. Clean up tasks.json/launch.json
1. Set 'DEBUGTELEMETRY' on launch since gdpr is updated daily now
2018-10-23 14:03:01 -07:00
Eric Jizba eba0da098c
Fix C# project creation logic to handle 'netcoreapp' (#754)
Looks like C# project used to default to 'netstandard2.0' and now they default to 'netcoreapp2.1'
2018-10-22 13:34:24 -07:00
Eric Jizba ca07655fb1
Add test for createFunctionApp API (#728)
And clean up tslint.json files
2018-10-17 22:23:31 +00:00
Eric Jizba c40dcf9038
Run tests against staging templates (#718) 2018-10-17 21:11:57 +00:00
Eric Jizba 90ede2d352
Refactor to use new tree (#689) 2018-10-04 22:21:43 +00:00
Nathan 11a91cc08c
Integration tests for Azure commands (#494)
* Integration tests for creating and deleting Function Apps
* Global "longRunningTestsEnabled" variable that will disable tests that tend to run long
2018-10-03 16:09:30 -07:00
Eric Jizba 27fca59824
Add Cosmos DB trigger to verified category for C# (#674) 2018-10-01 21:38:46 +00:00
Eric Jizba 31bd9063f7
Improve tests (#663)
Includes the following:
1. Fix template tests so that we guarantee it's testing against cli feed _and_ backup templates (current code was just testing against cli feed twice)
1. Remove a little bit of duplicate code in suiteSetup
1. Turn off telemetry for tests
1. Allow running a subset of tests with MOCHA_grep (super excited about this one - thanks Stephen)
2018-09-25 22:38:45 +00:00
Eric Jizba b5b681ead6
Add service bus to verified templates (#607)
Now that we have support for installing func extensions, we can add a few more templates to the "verified" category.
2018-09-18 18:35:44 -07:00
Eric Jizba 0c0829d4d4
Use long running notification when creating a project (#600) 2018-09-18 09:55:04 -07:00
Eric Jizba de998312f0
Add python verified templates (#585)
And Cosmos DB trigger to v2 JavaScript
2018-09-12 16:40:48 -07:00
Eric Jizba 38b781d852
Change beta to ~2 (#581) 2018-09-12 15:11:35 -07:00
Hanxiao Liu 816a4392bb Add guide for users to set maven path. (#530) 2018-09-07 15:30:07 -07:00
Nathan 494e20331e
Python Project Creating/Local Debugging (#525)
Create and locally debug Python functions projects.  Option to create is still hidden as Python is still in preview and we are working on the deployment scenario.

In order to debug, `python -m pip install --pre ptvsd` must be run within the project's virtual environment.  There is also a dependency on the experimental Python Extension, but they should release on Tuesday, 9/5/2018.
2018-08-31 14:51:56 -07:00
Eric Jizba f23e8ba84b
Ensure C# runtime logic is always run (#506) 2018-08-13 13:24:47 -07:00
Eric Jizba eb435356ab
Add a few more verified templates to C# v1 (#463)
Since we now have more templates available, I tried to make this list match the verified templates for JavaScript. v2 is exactly the same for both (just 4 templates). JavaScript has 8 for v1 while C# only has 7 (it's missing the ManualTrigger for some reason).
2018-07-18 10:51:45 -07:00
Eric Jizba 3c65d5596b
Dynamically retrieve .NET templates (#457) 2018-07-17 16:12:42 -07:00
Eric Jizba 8eab563b92
Register common variables rather than passing them to shared package all the time (#434) 2018-07-09 13:14:44 -07:00
Eric Jizba e416969796
Make function.json parsing less strict (#409) 2018-06-25 14:46:40 -07:00
Eric Jizba 63c8ccdb91
Fix func update for brew and add uninstall (#425) 2018-06-25 14:46:18 -07:00
Stephen Weatherford ea850bd7ae Fix build 2018-06-20 14:47:09 -07:00
Eric Jizba 46e6ab7b9e
Automatically retrieve dotnet templates from cli feed (#421) 2018-06-20 10:25:19 -07:00
Nathan fd7ebf96d4
Nturinski/fix test (#390)
* Add input for installing func cli prompt
2018-05-22 11:04:22 -07:00
Nathan 5eb4973ced Fix getting templates when offline and clean up getting templates (#373) 2018-05-15 09:03:26 -07:00
Nathan 69d4de3803
Nturinski/backout backups (#354)
* Remove resource/templates, add backup user setting
* Fixes semver issue, refactor verifyTemplates
2018-05-08 16:58:25 -07:00
Nathan 174e62c176
Check local version with func and update if possible (#339)
* Check local version with func and update if possible
* Disable code regarding updating func core tools
* Link to issue regarding func --version
2018-05-01 16:51:02 -07:00
Nathan e11c430fc4
Download zip from Func Cli Feed (#330)
Retrieve function templates from the Func Cli Feed as a zip
2018-04-25 14:27:38 -07:00
Eric Jizba ca05495158
Allow creating storage account for AzureWebJobsStorage (#329)
I also moved the warning to after all of the function-creation stuff. That ways its less in-your-face. Plus creating a storage account can take a while and we don't want to stop the user from creating a function during that time
2018-04-19 18:17:50 +00:00
Eric Jizba f5a7e1747e
Rename files with '#' in the name (#316)
VS Code doesn't handle files with '#' in the name well
2018-04-10 15:23:03 +00:00
Eric Jizba 429a65a7bd
Allow function to be created with project from api (#303) 2018-03-30 01:11:54 +00:00
Eric Jizba 6fcaec17d3
Refactor project constants (#295)
As described in this PR https://github.com/Microsoft/vscode-azurefunctions/pull/269 I wanted to leverage some constants instead of repeatedly typing out 'host.json', 'local.settings.json' and '.gitignore'. I also moved several things from the ProjectSettings file to the constants file. I think the ProjectSettings file has a confusing name and I'd like to refactor that as a part of https://github.com/Microsoft/vscode-azurefunctions/issues/251 anyways
2018-03-26 17:31:43 +00:00
Eric Jizba 7aa966ad7e
Allow users to change settings when picking templates (#289)
I honestly don't think users will change their runtime/language very often - this is much more about the visibility of the settings. Previously user's didn't know the settings even existed and didn't know what it was set to. That's why I wanted to make sure these never show up at the top as "(recently used)".

The other big difference is that JavaScript projects will now default the runtime to the user's locally installed runtime (if we can detect the version). The positive: Users will have more consistent behavior between their local/remote function apps. The negative: "beta" users will see many fewer templates since "beta" doesn't have as many as "~1"
2018-03-22 21:36:15 +00:00
Eric Jizba c5ccd14b27
Move over to shared UserInput (#282)
This fully moves over to the shared UserInput. A few highlights:
1. My old implementation of QuickPickItems, showInputBox, and showQuickPick in this repo had actually diverged from the vscode implementation. I regret doing that now and a lot of this is just moving back to the vscode patterns
1. Remove a custom implementation of displaying subscriptions and switch over to showNodePicker
1. Make the 'showWorkspaceFolder' more similar to app service extension (where it displays path.basename as the label and the full path as the description)
2018-03-16 00:20:45 +00:00
Eric Jizba 0d05ca4876
Add telemetry to a few more places (#256)
Added telemetry to the following:
1. activate method
1. validateFunctionRuntime
1. timeout to pickProcess
2018-03-07 14:05:52 -08:00
Eric Jizba 86053f012e
Allow runtime in createNewProject api (#252) 2018-03-02 15:22:50 -08:00
Eric Jizba bb1911e393
Leverage refactored telemetry (#248)
This lets us use `callWithTelemetryAndErrorHandling` for validating projects. I also added the validateProjects command to run with the onDidChangeWorkspaceFolders event
2018-03-01 15:00:40 -08:00
Eric Jizba 6bf5000896
Improve support for projects created outside of VS Code (#246)
On extension activation, we will check for unitialized functions projects based on the following criteria:
1. host.json and local.settings.json exist
1. projectLanguage and projectRuntime are not set

We will then initialize the project in the following manner:
1. If we can _uniquely_ detect the language - use that. If we can't, prompt the user for the langauge
1. If we can detect the installed runtime - use that. Otherwise, prompt the user for the runtime
1. Remove '.vscode' from the gitignore if applicable

NOTE: I also added a command so that user's can call this from the command palette if they so desire
2018-03-01 11:13:46 -08:00
Eric Jizba 7e8ea219d8
Change 'Create function api' to accept object for function settings (#242)
This is better in a few ways:
1. It eliminates the need for the settings to always be in the same order
1. It allows us to add optional parameters in the future in a backwards compatible format
2018-02-23 16:09:12 -08:00
Eric Jizba 0e3d36b9d0 Ship backup versions of templates with vsix (#237)
And improve unit testing/telemetry around template data
2018-02-22 14:40:37 -08:00
Eric Jizba a7fca0467a
Make warnings consistent (#212)
For the 64 bit warning, it now opens the link directly with a 'See more info' instead of having to copy the link. There's also a 'Don't warn again' option
2018-02-09 16:25:41 +00:00
Eric Jizba dee40a83ed
Support Function projects in multi-root workspaces (#210)
Our project settings were being completely ignored in multi-root workspaces. Here's what I did to fix that:
1. Declare our project-based settings as 'resource' scope (If you use the default scope of 'window', then settings only apply at the user/workspace level - not the workspaceFolder level)
1. Pass the projectPath in when getting settings so that the specific folder takes precedent
1. Modify the workspace folder picker so that it dynamically gets the subpath for each folder
1. Fix 'update' for mutli-root settings: If you don't pass the ConfiguratonTarget, it uses the appropriate scope from the configuration (Workspace vs WorkspaceFolder)
2018-02-07 21:55:45 +00:00
Eric Jizba afbf0e7a67 subPath -> subpath 2018-01-24 13:29:52 -08:00
Eric Jizba d236d8c519 Improve C# template installation
1. Allow windows users to install either the .NET Core _or_ .NET Framework templates
1. Provide commands to install/uninstall the templates
1. Limit function templates to just the main 4
1. Detect if the project created was .NET Core or .NET Framework and set runtime accordingly
2018-01-24 13:29:52 -08:00
Eric Jizba d61db5d4ad Add local debug support for C# Scripts 2018-01-24 12:03:01 -08:00
Eric Jizba 283d77109b Add preview support for several script languages 2018-01-24 12:03:01 -08:00
Eric Jizba 00941569ca C# functions - prompt for namespace 2018-01-22 10:37:04 -08:00
Eric Jizba 198a3486be Fix function.json parsing for C# functions
They don't require the direction information
2018-01-18 14:36:17 -08:00
Eric Jizba 767808b70b Increase timeout for a few tests 2018-01-17 14:02:32 -08:00
Eric Jizba 3d42f2ab35 Default ignoreFocusOut to true 2018-01-17 13:45:29 -08:00
Eric Jizba 7fe28b5a79
Add support for C# Class library projects (#161)
This supports project/function creation and local debugging. It does not include deploy logic.

A brief summary:
1. We default C# projects to beta runtime and class library (instead of C# script)
1. We use dotnet templates for project/function creation. We will automatically install the templates for the user if they are not on their machine (I don't prompt at all - let me know if you think we should prompt).
1. We use the parameter information from the functions portal (Aka C# Script templates) since it's easier to parse than the dotnet cli and it gives us more information (like validation). This requires us to assume that parameters for C# Scripts are the same as the parameters for the C# Class libraries. Since that might not always be the case, I mitigated this with unit tests and hard-coding the version of the dotnet templates.
1. Unlike JavaScript debugging, we have to attach to a specific process instead of attaching with a port. I implemented a 'pickProcess' command to search for the functions host process.
1. This only works on Windows. There's a few issues on a Mac I still need to iron out.
2018-01-11 17:37:52 -08:00
Eric Jizba 4af25798c3 Allow programatic use of deploy, createFunction, and createNewProject 2018-01-11 11:28:00 -08:00
Eric Jizba bf2b67589c
Leverage shared AzureActionHandler (#150) 2018-01-04 15:06:57 -08:00
Eric Jizba b3154f8ba2 Move browse to the bottom of the list of folders 2018-01-04 10:09:07 -08:00
Eric Jizba a8a8276378 Split function/project creation into separate files
This helps isolate language-specific code and will be more important as we add C# class library support. It should have no functional effect.
2018-01-02 13:42:04 -08:00
Eric Jizba c0c0503e65 Remove C# script file support
Turns out we want to add support for class libraries (.cs), but this code added support for C# script files (.csx). I want to leave this code in the git history in case we add support for .csx _in addition_ to .cs
2017-12-14 11:25:34 -08:00
Eric Jizba 8c894060b8 Add support for other languages/runtimes
* Add CSharp to the list of options when creating a new project
* Add setting for projectLanguage
  * The user has many options for language, but only C#/Java/JavaScript can be debugged in VS Code today. The rest only support create & deploy
  * If it's not set (for example in old projects before this release), the user will be prompted one time and their workspace setting will be updated
* Add setting for projectRuntime
  * We want to use ~1 for JavaScript and beta as the default for Java/C#
2017-12-14 11:25:34 -08:00