### Format Code Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/intro.md Formats the codebase to adhere to the project's style guide using a PowerShell script. This ensures code consistency across contributions. ```powershell .\src\FormatCode.ps1 ``` -------------------------------- ### Find/Replace 'Start' Invocation Requirement Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/src/Notes_V3.md Ensures that the 'Start' button must be invoked before 'Replace all' in the Find/Replace functionality. ```csharp // UI workflow and validation for Find/Replace operations. ``` -------------------------------- ### Install Development Tools with PowerShell Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/installing-the-dependencies.md Installs essential development tools like Visual Studio Build Tools and NuGet using a PowerShell script. Requires administrator privileges for installation. An option for a dry run is available to list tools without installation, which does not require admin privileges. ```powershell $.\src\InstallToolsForDevelopment.ps1 ``` ```powershell $.\src\InstallToolsForDevelopment.ps1 -DryRun ``` -------------------------------- ### Install Solution Dependencies with PowerShell Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/installing-the-dependencies.md Installs all solution-specific dependencies, including tools for build-test-inspect workflow, code style conformance, third-party libraries (NuGet), and sample AASX packages. This script should not require admin privileges. Re-running this script is necessary when dependencies change. ```powershell .\src\InstallSolutionDependencies.ps1 ``` -------------------------------- ### Clone Git Repository Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/intro.md Clones the aasx-package-explorer Git repository from GitHub. This is the first step to obtain the project's source code for local development. ```git git clone https://github.com/admin-shell-io/aasx-package-explorer ``` ```git git clone https://github.com/yourUsername/aasx-package-explorer ``` -------------------------------- ### SME Refactor Example (SMC to Event Element) Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/src/Notes_V3.md Addresses an issue where the SME (Submodel Element) refactoring process was not functioning correctly, using the example of converting an SMC to an event element. ```csharp // Refactoring logic for Submodel Elements. ``` -------------------------------- ### Initializing DefinitionsPool in Package Explorer Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/src/Notes_V3.md This code demonstrates the instantiation of a SelectFromReferablesPoolFlyout, which is used when adding known submodels. It highlights a potential lag issue related to the creation of new pool objects. ```csharp var uc = new SelectFromReferablesPoolFlyout(AasxPredefinedConcepts.DefinitionsPool.Static); public static DefinitionsPool Static { get { return thePool; } } ``` -------------------------------- ### Push Changes Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/intro.md Pushes the local commits to the remote repository. This makes your changes available on the remote server for review and merging. ```git git push ``` -------------------------------- ### Example LICENSE.txt Header Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/licenses-and-copyrights.md An example of the header section for the main `LICENSE.txt` file. It lists copyright holders, their contact information, and the primary software license, followed by references to dependency licenses. ```text Copyright (c) 2018-2020 Festo AG & Co. KG Author: Michael Hoffmeister Copyright (c) 2019-2020 PHOENIX CONTACT GmbH & Co. KG Author: Andreas Orzelski Copyright (c) 2019-2020 Fraunhofer IOSB-INA Lemgo, eine rechtlich nicht selbstaendige Einrichtung der Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V. Copyright (c) 2020 Schneider Electric Automation GmbH Author: Marco Mendes ... more contributors ... This software is licensed under the Apache License 2.0 (Apache-2.0) (see below) The browser functionality is licensed under the cefSharp license (see below) The QR code generation is licensed under the MIT license (MIT) (see below) ... more references to dependencies ... ``` -------------------------------- ### Create Feature Branch Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/intro.md Creates a new branch for developing a specific feature. The branch naming convention is '{your-username}/{Describe-subject-of-the-commit}'. ```git git checkout -b yourUsername/Add-some-new-feature ``` -------------------------------- ### Add Files for Commit Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/intro.md Stages specific files for the next commit. This command adds the changes in the specified file to the staging area. ```git git add src/AasxSomeProject/SomeFile.cs ``` -------------------------------- ### Example Dependency License in LICENSE.txt Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/licenses-and-copyrights.md An example of how a dependency's license is presented in the body of the `LICENSE.txt` file. It typically includes a URL to the license and the license text itself, often with comments indicating the source. ```text With respect to cefSharp ========================= (https://raw.githubusercontent.com/cefsharp/CefSharp/master/LICENSE) // Copyright © The CefSharp Authors. All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are // met: ... ``` -------------------------------- ### Set Upstream Branch Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/intro.md Sets the upstream tracking branch for the current local branch. This is essential for pushing and pulling changes to and from the remote repository. ```git git branch --set-upstream-to origin/yourUsername/Add-some-new-feature ``` -------------------------------- ### Run Pre-Commit Checks Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/intro.md Executes a PowerShell script to run pre-commit checks. This ensures that the code meets the project's quality and compliance standards before committing. ```powershell .\src\Check.ps1 ``` -------------------------------- ### Amend Last Commit Source: https://github.com/eclipse-aaspe/package-explorer/blob/main/docdev/docfx_project/getting-started/intro.md Modifies the last commit, typically to change the commit message or add forgotten files. Use with caution, especially after pushing changes. ```git git commit --amend ```