Skip to content

Commit

Permalink
Merge pull request #192 from microsoft/staging
Browse files Browse the repository at this point in the history
Release - 5/19/24
  • Loading branch information
EricJohnson327 authored May 20, 2024
2 parents 7654af5 + 753e10c commit cf7ebb0
Show file tree
Hide file tree
Showing 190 changed files with 51,160 additions and 412 deletions.
7 changes: 7 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -208,3 +208,10 @@ dotnet_style_prefer_simplified_interpolation = true:suggestion
spelling_exclusion_path = .\exclusion.dic
spelling_error_severity = warning

# Diagnostic configuration

# CS8305: Type is for evaluation purposes only and is subject to change or removal in future updates.
dotnet_diagnostic.CS8305.severity = suggestion

[src/AzureExtension/Assets/QuickStartPlayground/Samples/csharp-hello-world/Program.cs]
dotnet_diagnostic.SA1633.severity = none
5 changes: 5 additions & 0 deletions build/SyncMirroredRepository.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
variables:
DisableDockerDetector: true
cfsNpmWarnLevel: 'warn'
cfsCargoWarnLevel: 'warn'

resources:
repositories:
- repository: m365Pipelines
Expand Down
23 changes: 13 additions & 10 deletions build/azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,13 @@ parameters:
- release

variables:
MSIXVersion: '0.800'
MSIXVersion: '0.900'
solution: '**/DevHomeAzureExtension.sln'
appxPackageDir: 'AppxPackages'
testOutputArtifactDir: 'TestResults'
DisableDockerDetector: true
cfsNpmWarnLevel: 'warn'
cfsCargoWarnLevel: 'warn'

resources:
repositories:
Expand Down Expand Up @@ -83,13 +86,13 @@ extends:
nugetConfigPath: 'nuget.config'
externalFeedCredentials: 'DevHomeInternal'

- task: MicrosoftTDBuild.tdbuild-task.tdbuild-task.TouchdownBuildTask@1
- task: MicrosoftTDBuild.tdbuild-task.tdbuild-task.TouchdownBuildTask@3
displayName: Send and Download Localization Files for Artifacts
condition: and(eq(variables['EnableLocalization'], 'true'), eq(variables['UpdateLocalization'], 'true'))
inputs:
teamId: 89242
authId: $(TouchdownAppId)
authKey: $(TouchdownAppKey)
TDBuildServiceConnection: $(TouchdownServiceConnection)
authType: SubjectNameIssuer
resourceFilePath: |
**\en-US\*.resw;P:466
**\en-US\PDP.xml
Expand All @@ -98,14 +101,14 @@ extends:
appendRelativeDir: true
pseudoSetting: Included

- task: MicrosoftTDBuild.tdbuild-task.tdbuild-task.TouchdownBuildTask@1
- task: MicrosoftTDBuild.tdbuild-task.tdbuild-task.TouchdownBuildTask@3
displayName: Download and Use Localization Files
condition: eq(variables['EnableLocalization'], 'true')
retryCountOnTaskFailure: 2
inputs:
teamId: 89242
authId: $(TouchdownAppId)
authKey: $(TouchdownAppKey)
TDBuildServiceConnection: $(TouchdownServiceConnection)
authType: SubjectNameIssuer
resourceFilePath: |
**\en-US\*.resw;P:466
**\en-US\PDP.xml
Expand Down Expand Up @@ -365,14 +368,14 @@ extends:
artifactName: MsixBundle_Release
targetPath: StorePublish

- task: MicrosoftTDBuild.tdbuild-task.tdbuild-task.TouchdownBuildTask@1
- task: MicrosoftTDBuild.tdbuild-task.tdbuild-task.TouchdownBuildTask@3
displayName: Download and Use Localization Files
condition: eq(variables['EnableLocalization'], 'true')
retryCountOnTaskFailure: 2
inputs:
teamId: 89242
authId: $(TouchdownAppId)
authKey: $(TouchdownAppKey)
TDBuildServiceConnection: $(TouchdownServiceConnection)
authType: SubjectNameIssuer
resourceFilePath: |
**\en-US\PDP.xml
localizationTarget: false
Expand Down
2 changes: 1 addition & 1 deletion build/scripts/CreateBuildInfo.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Param(
)

$Major = "0"
$Minor = "8"
$Minor = "9"
$Patch = "99" # default to 99 for local builds

$versionSplit = $Version.Split(".");
Expand Down
Binary file modified src/AzureExtension/Assets/DevBoxThumbnail.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
FROM mcr.microsoft.com/devcontainers/base:ubuntu

ENV DEBIAN_FRONTEND noninteractive

RUN apt update && \
apt install -y python3-pip python3-tk
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"name": "Python 3 Bitcoin Price Tracker",
"build": {
"dockerfile": "Dockerfile"
},
"customizations": {
// Configure properties specific to VS Code.
"vscode": {
"settings": {},
"extensions": [
"ms-python.python"
]
}
},
"postCreateCommand": "pip3 install -r requirements.txt"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Python: Bitcoin Price Tracker",
"type": "python",
"request": "launch",
"program": "price_tracker.py"
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Bitcoin Price Tracker

This repository contains a Python 3 application that tracks the current price of Bitcoin.

## Setup

To set up the application, you will need to install the necessary dependencies. To do this, run the following command:

```
pip install -r requirements.txt
```

## Running the App

To start the app, run the following command:

```
python price_tracker.py
```

This will print out the current price of Bitcoin.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
python
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Create a bitcoin price tracker using Python
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import requests

url = 'https://api.coindesk.com/v1/bpi/currentprice.json'

response = requests.get(url)
data = response.json()

print("Bitcoin Price: $" + data['bpi']['USD']['rate'])
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
requests
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
FROM mcr.microsoft.com/devcontainers/base:ubuntu

ENV DEBIAN_FRONTEND noninteractive

RUN apt-get update && \
apt-get install -y g++ gdb gcc clang cmake tar
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "C++",
"build": {
"dockerfile": "Dockerfile"
},
"customizations": {
// Configure properties specific to VS Code.
"vscode": {
"settings": {},
"extensions": [
"ms-vscode.cpptools"
]
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Launch Main",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/main.out",
"args": [],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"MIMode": "gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
],
"preLaunchTask": "Build Main"
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "Build Main",
"type": "shell",
"command": "g++ -g main.cpp -o main.out",
"group": {
"kind": "build",
"isDefault": true
}
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Set up

Run `g++ -g main.cpp -o main.out`

# Get started

Run `./main.out`
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
c++
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Create a VS Code Codespaces ready environment to get started with a hello world application using C++
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#include <iostream>
#include <string>

using namespace std;

int main()
{
cout << "Hello World\n";
cout << "Input: ";
string data;
getline(cin, data);
cout << "Output: " << data << "\n\n";
return 0;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
==== EXAMPLE PROMPT: Create a VS Code Codespaces ready environment to get started with a hello world application using C++ ====
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
FROM mcr.microsoft.com/devcontainers/base:ubuntu

ENV DEBIAN_FRONTEND noninteractive

RUN apt update && \
apt install -y build-essential g++ libsdl2-dev gdb
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"name": "C++ game",
"build": {
"dockerfile": "Dockerfile"
},
"customizations": {
// Configure properties specific to VS Code.
"vscode": {
"settings": {},
"extensions": [
"ms-vscode.cpptools"
]
}
}
}

Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"files.associations": {
"iostream": "cpp"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# C++ simple game

This repository contains a game written in C++ where you can move a character with the keyboard.

## Running the Game

1. Run `g++ -o game main.cpp -lSDL2` to build the game binary
2. Run `./game`
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
c++
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Create a VS Code Codespaces ready environment to get started with a simple game using C++
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
#include <SDL2/SDL.h>
#include <iostream>

const int SCREEN_WIDTH = 800;
const int SCREEN_HEIGHT = 600;

int main(int argc, char* args[]) {
SDL_Window* window = NULL;
SDL_Surface* screenSurface = NULL;

if (SDL_Init(SDL_INIT_VIDEO) < 0) {
std::cout << "SDL could not initialize! SDL_Error: " << SDL_GetError() << std::endl;
} else {
window = SDL_CreateWindow("SDL Tutorial", SDL_WINDOWPOS_UNDEFINED, SDL_WINDOWPOS_UNDEFINED, SCREEN_WIDTH, SCREEN_HEIGHT, SDL_WINDOW_SHOWN);
if (window == NULL) {
std::cout << "Window could not be created! SDL_Error: " << SDL_GetError() << std::endl;
} else {
screenSurface = SDL_GetWindowSurface(window);
SDL_FillRect(screenSurface, NULL, SDL_MapRGB(screenSurface->format, 0xFF, 0xFF, 0xFF));
SDL_UpdateWindowSurface(window);
SDL_Delay(2000);
}
}

SDL_Rect player;
player.x = 370;
player.y = 480;
player.w = 20;
player.h = 20;

bool quit = false;
SDL_Event e;
while (!quit) {
while (SDL_PollEvent(&e) != 0) {
if (e.type == SDL_QUIT) {
quit = true;
} else if (e.type == SDL_KEYDOWN) {
switch (e.key.keysym.sym) {
case SDLK_LEFT:
player.x -= 1;
break;
case SDLK_RIGHT:
player.x += 1;
break;
case SDLK_UP:
player.y -= 1;
break;
case SDLK_DOWN:
player.y += 1;
break;
}
}
}
SDL_FillRect(screenSurface, NULL, SDL_MapRGB(screenSurface->format, 0xFF, 0xFF, 0xFF));
SDL_FillRect(screenSurface, &player, SDL_MapRGB(screenSurface->format, 0x00, 0xFF, 0x00));
SDL_UpdateWindowSurface(window);
}

SDL_DestroyWindow(window);
SDL_Quit();

return 0;
}

Loading

0 comments on commit cf7ebb0

Please sign in to comment.