Skip to content

Commit 203600e

Browse files
authored
Merge pull request #129 from MYRhouma/patch-1
Add Mac OS setup guide for Apple Silicon
2 parents 9e5985a + c22a8bf commit 203600e

1 file changed

Lines changed: 40 additions & 1 deletion

File tree

docs/en/homework/index.md

Lines changed: 40 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Homework
1+
# Homework
22

33
With these exercises, you can earn **points** that are added to your exam score. In the exercises and the evaluation results, you will see a text “iMsc” for optional exercises; these iMsc points are not counted! (These are special points for the Hungarian curriculum). All non-iMsc exercises are available for points in this course, 5 homeworks, with a maximum of 4 points per homework, for a total of 20 points. Here you find the exercise descriptions; the submission of the solutions is expected via GitHub Classroom. If you fail to submit the exercises exactly as in the guide, or if it is submitted late, you get no points at all! Make sure to follow the guide and do **everything in time**!
44

@@ -34,6 +34,45 @@ Some of the exercises require you to create a screenshot. This screenshot is pro
3434
- Windows, Linux, or macOS: All tools are platform-independent, or a platform-independent alternative is available.
3535
- A [GitHub](https://github.com/) account and a [git](https://git-scm.com/) client.
3636

37+
### MAC OS / Apple Silicon Setup Guide
38+
39+
If you are using a Mac with an Apple Silicon processor, you cannot run the full Windows version of Visual Studio. Instead, you should use a **native** development workflow using VS Code and Docker.
40+
41+
1. **Development Environment (Native macOS):**
42+
* **Install .NET SDK:** Download and install the **.NET 8.0 SDK (Arm64)** from the [official Microsoft website](https://dotnet.microsoft.com/en-us/download/dotnet/8.0).
43+
* **Install VS Code:** Download [Visual Studio Code for macOS](https://code.visualstudio.com/download).
44+
* **Install Extensions:** Open VS Code and install the following extensions to handle C#, SQL, and MongoDB homeworks:
45+
* [C# Dev Kit](https://marketplace.visualstudio.com/items?itemName=ms-dotnettools.csdevkit) (for writing the code)
46+
* [SQL Server (mssql)](https://marketplace.visualstudio.com/items?itemName=ms-mssql.mssql) (for managing the MSSQL database)
47+
* [MongoDB for VS Code](https://marketplace.visualstudio.com/items?itemName=mongodb.mongodb-vscode) (for the MongoDB homework)
48+
49+
2. **SQL Server Database (Docker):**
50+
You cannot install SQL Server directly on macOS, so you must use Docker.
51+
52+
**Step A: Install Docker Desktop**
53+
* Download "Docker Desktop for Mac with Apple silicon" from the [Docker Website](https://www.docker.com/products/docker-desktop/) or install via Homebrew (`brew install --cask docker`).
54+
55+
**Step B: Start the Database**
56+
Open your macOS Terminal and run the following command. This creates a container named `database-sql`.
57+
58+
```bash
59+
docker run -e "ACCEPT_EULA=Y" \
60+
-e "MSSQL_SA_PASSWORD=YourStrong@Passw0rd" \
61+
-p 1433:1433 \
62+
--name database-sql \
63+
-d [mcr.microsoft.com/mssql/server:2022-latest](https://mcr.microsoft.com/mssql/server:2022-latest)
64+
```
65+
66+
3. **Connecting to the Database:**
67+
* **From VS Code:** Use the SQL Server extension you installed. Connect to `localhost` with username `sa` and the password you defined above.
68+
* **From C# Code:** Update your `ConnectionString` in `appsettings.json`.
69+
```json
70+
"DefaultConnection": "Server=localhost;Database=master;User Id=sa;Password=YourStrong@Passw0rd;TrustServerCertificate=True;"
71+
```
72+
*Note regarding the Database name: In the Docker command, `--name database-sql` names the container. In the connection string, `Database=master` refers to the logical database. You may need to change `master` to the specific database name created by the homework script (e.g., `mssql.sql`) once you run it.*
73+
74+
---
75+
3776
### For homework using the MSSQL platform:
3877
- Microsoft SQL Server. The free _Express_ version is sufficient, or you may also use the _localdb_ installed with Visual Studio.
3978
- A [Ubuntu Linux 22.04 version](https://docs.microsoft.com/en-us/sql/linux/sql-server-linux-setup) is also available, or

0 commit comments

Comments
 (0)