Skip to content

Commit

Permalink
Merge branch 'main' into bugfix/1170
Browse files Browse the repository at this point in the history
  • Loading branch information
btiteux authored May 26, 2024
2 parents fd456e2 + 8d4ea06 commit ba09acf
Show file tree
Hide file tree
Showing 470 changed files with 9,946 additions and 6,377 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
name: ci

on:
push:
pull_request:
branches:
- '!crowdin_main' # excludes crowdin_main
- main

jobs:
windows-latest:
name: windows-latest
name: Windows
runs-on: windows-latest
timeout-minutes: 30
steps:
Expand All @@ -22,7 +22,7 @@ jobs:
- name: 'Restore, Build and Test'
run: ./build.cmd RunTests
ubuntu-latest:
name: ubuntu-latest
name: Ubuntu
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
Expand All @@ -37,7 +37,7 @@ jobs:
- name: 'Restore, Build and Test'
run: ./build.cmd RunTests
macos-latest:
name: macos-14
name: macOS
runs-on: macos-14
timeout-minutes: 30
steps:
Expand Down
4 changes: 2 additions & 2 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"preLaunchTask": "Build DevToys MacOS",
"type": "coreclr",
"request": "launch",
"program": "${workspaceFolder}/bin/Debug/AnyCPU/DevToys.MacOS/net8.0-macos/osx-arm64/DevToys.MacOS.app/Contents/MacOS/DevToys.MacOS",
"program": "${workspaceFolder}/bin/Debug/AnyCPU/DevToys.MacOS/net8.0-macos/osx-arm64/DevToys.app/Contents/MacOS/DevToys",
"args": [],
"cwd": "${workspaceFolder}/src/app/dev/platforms/desktop/DevToys.MacOS",
// For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console
Expand All @@ -28,7 +28,7 @@
"preLaunchTask": "Build DevToys MacOS",
"type": "coreclr",
"request": "launch",
"program": "${workspaceFolder}/bin/Debug/AnyCPU/DevToys.MacOS/net8.0-macos/osx-x64/DevToys.MacOS.app/Contents/MacOS/DevToys.MacOS",
"program": "${workspaceFolder}/bin/Debug/AnyCPU/DevToys.MacOS/net8.0-macos/osx-x64/DevToys.app/Contents/MacOS/DevToys",
"args": [],
"cwd": "${workspaceFolder}/src/app/dev/platforms/desktop/DevToys.MacOS",
// For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console
Expand Down
92 changes: 13 additions & 79 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
# How to Contribute:

You can contribute to DevToys app by:
- Report issues and bugs [here](https://github.com/veler/DevToys/issues/new?template=bug_report.md).
- Submit feature requests [here](https://github.com/veler/DevToys/issues/new?template=feature_request.md).
- Report issues and bugs [here](https://github.com/DevToys-app/DevToys/issues/new?template=bug_report.md).
- Submit feature requests [here](https://github.com/DevToys-app/DevToys/issues/new?template=feature_request.md).
- Creating a pull request.
- Internationalization and localization:
* See instructions below.
* See instructions [here](#internationalization-and-localization).

# How to Build and Run DevToys from source:
# How to Build and Run DevToys and DevToys CLI (without tools) from source:

## From Windows

### Prerequisites
1. Make sure your machine is running on Windows 10 1903 (19h1) or later.
1. Install [Visual Studio 2022 17.3 or later](https://visualstudio.microsoft.com/vs/) installed with the following Workloads, or import the [vs2022.vsconfig](vs2022.vsconfig) file.
1. Install [**Visual Studio 2022 17.3 or later**](https://visualstudio.microsoft.com/vs/) installed with the following Workloads, or import the [vs2022.vsconfig](vs2022.vsconfig) file.
* ASP.NET and web development
* Node.js development
* .NET desktop development
Expand Down Expand Up @@ -78,9 +78,9 @@ You can contribute to DevToys app by:
#### Special note for `DevToys.MacOS`
Most of the `DevToys.MacOS` app runs in a web browser (Safari). In order to access the Safari developer tools with macOS to debug the HTML/CSS/JS of the Blazor app, you might need to follow the following instructions:
1. Open desktop Safari.
2. Select the Safari > Preferences > Advanced > Show Develop menu in the menu bar checkbox.
2. Select the Safari > Preferences > Advanced > Show features for web developers in the menu bar checkbox.
3. Run the `DevToys.MacOS` app in macOS.
4. Return to Safari. Select Develop > {REMOTE INSPECTION TARGET} > 0.0.0.0, where the {REMOTE INSPECTION TARGET} placeholder is either the devices's plain name (for example, MacBook Pro) or the device's serial number (for example XMVM7VFF10). If multiple entries for 0.0.0.0 are present, select the entry that highlights the BlazorWebView. The BlazorWebView is highlighted in blue in macOS when the correct 0.0.0.0 entry is selected.
4. Return to Safari. On the main menu, select Develop > {REMOTE INSPECTION TARGET} > 0.0.0.0, where the {REMOTE INSPECTION TARGET} placeholder is either the devices's plain name (for example, MacBook Pro) or the device's serial number (for example XMVM7VFF10). If multiple entries for 0.0.0.0 are present, select the entry that highlights the BlazorWebView. The BlazorWebView is highlighted in blue in macOS when the correct 0.0.0.0 entry is selected.
5. The Web Inspector window appears for the BlazorWebView.

## From Linux
Expand Down Expand Up @@ -117,82 +117,16 @@ Most of the `DevToys.MacOS` app runs in a web browser (Safari). In order to acce
1. Open the repository in Visual Studio Code to edit the code.
1. In `Run and Debug`, select `DevToys Linux` or `DevToys CLI` and press Start.

# Internationalization and localization
# How to Build and Run DevToys and DevToys CLI with default tools from source:

See [DevToys.Tools's CONTRIBUTING.md](https://github.com/DevToys-app/DevToys.Tools/blob/main/CONTRIBUTING.md) file.

There are two possibilities offered:
# Internationalization and localization

## Use Crowdin (preferred)
Please use Crowdin to translate DevToys and its tools. Crowdin is a localization management platform that helps individuals to translate a project without having to be familiar with its repository.

* Go on [DevToy's Crowdin project](https://crowdin.com/project/devtoys). Crowdin is a localization management platform that helps individuals to translate a project without having to be familiar with its repository.
* Go on [DevToy's Crowdin project](https://crowdin.com/project/devtoys).
* Log in or create an account. Join the DevToys project.
* Select the language of your choice in the list of existing supported language and let yourself guided by the website to translate the app.
* If you want to add a new language, please create a new discussion on Crowdin's website or on GitHub. We will be happy to add your language to the list.
* When your translation is done, it will be synchronized with our GitHub repository within 1 hour and create a pull request.

## Change the translations in the repository yourself

This approach is more complex but has the advantage that it allows you to test your changes on your local machine.

* After following `How to Build and Run DevToys from source`, close Visual Studio, if any instance is running.
* In File Explorer, copy the folder `dev/impl/DevToys/Strings/en-US` and rename the copied folder with the language indication of your choice. For example, "fr-FR" for French (France).
* Open `src/DevToys.sln` with Visual Studio.
* Open each `.resw` file from the language folder you created and translate the text.
* Build and Run the app and test your changes.

# Coding

## Main architecture

// TODO

## Develop a tool

// TODO

## Iconography

Icons in the UI of a tool or in the main UI of DevToys uses [Fluent System Icons](https://github.com/microsoft/fluentui-system-icons).
For the icons of the tools, a custom font is used. See [documentation](https://github.com/veler/DevToys/blob/main/assets/font/README.md) here for modifying it (or ask us for help!).

## Sample

// TODO

## Things to keep in mind

We try to avoid at maximum any Microsoft Store app capability/permission like `internet`, `camera`, `location`...etc. The reason why is that this app is designed to be a tool that we can **trust** when pasting sensitive data inside.
Therefore, when making changes to DevToys, please try at maximum to avoid any capability requirement.

## Code Style

1. DO use `PascalCase`:
- class names
- method names
- const names

2. DO use `camelCase`:
- method arguments
- local variables
- private fields

4. DO NOT use Hungarian notation.

5. DO NOT use underscores, hyphens, or any other non-alphanumeric characters.

6. DO NOT use Caps for any names.

7. DO use predefined type names like `int`, `string` etc. instead of `Int32`, `String`.

8. DO use `_` prefix for private field names.

9. DO use the `I` prefix for Interface names.

10. DO vertically align curly brackets.

11. DO NOT use `Enum` or `Flag(s)` suffix for Enum names.

12. DO use prefix `Is`, `Has`, `Have`, `Any`, `Can` or similar keywords for Boolean names.

13. DO use curly brackets for single line `if`, `for` and `foreach` statements.

14. DO use nullable reference type by adding `#nullable enable` at the top of every C# file.
99 changes: 7 additions & 92 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,12 @@
A Swiss Army knife for developers.
</p>
<p align="center">
<a style="text-decoration:none" href="https://etienne-baudoux.visualstudio.com/DevToys/_build?definitionId=19&branchName=main" target="_blank">
<img src="https://etienne-baudoux.visualstudio.com/DevToys/_apis/build/status/DevToys?branchName=main" alt="Build Status" />
</a>
<a title="Crowdin" target="_blank" href="https://crowdin.com/project/devtoys">
<img src="https://badges.crowdin.net/devtoys/localized.svg">
</a>
<a style="text-decoration:none" href="https://github.com/DevToys-app/DevToys/releases" target="_blank">
<img src="https://img.shields.io/github/release/DevToys-app/DevToys.svg?label=Latest%20version" alt="Latest version" />
</a>
<a style="text-decoration:none" href="https://community.chocolatey.org/packages/devtoys" target="_blank">
<img src="https://img.shields.io/chocolatey/v/devtoys?include_prereleases" alt="Chocolatey Version (including pre-releases)">
</a>
<a style="text-decoration:none" href="https://www.microsoft.com/store/apps/9PGCV4V3BK4W" target="_blank">
<img src="https://img.shields.io/badge/Microsoft%20Store-Download-brightgreen" alt="Store link" />
</a>
<a style="text-decoration:none" href="https://devtoys.app" target="_blank">
<img src="https://img.shields.io/badge/Website-devtoys.app-blue" alt="Website" />
</a>
Expand Down Expand Up @@ -69,93 +60,12 @@ Many tools are available.

... and more are coming!

![DevToys](/assets/screenshots/1.png)
![DevToys](/assets/hero-screenshot.png)

## Rate on Microsoft Store as of 5/23/2022
## Rate on Microsoft Store as of 5/7/2024

![Microsoft Store rate](/assets/ms-store-rate.png)

## How to install (as an end-user)

### Prerequisite

- You need Windows 10 build 1903+ or later.

### Microsoft Store

- Search for DevToys in the Microsoft Store App or click [here](https://www.microsoft.com/store/apps/9PGCV4V3BK4W)

### Manual

- Download and extract the latest [release](https://github.com/veler/DevToys/releases).
- Double click the *.msixbundle file.
- Install.

### WinGet

- Open a PowerShell command prompt.
- Type `winget search DevToys` to search and see details about DevToys.
- Type `winget install DevToys` to install the app.

__Note:__ a Microsoft Store account is required for WinGet. We're trying to workaround it. See here https://github.com/microsoft/winget-pkgs/pull/43996

### Chocolatey

- Make sure you already have [Chocolatey](https://chocolatey.org/) installed on your computer.
- Open a PowerShell command prompt.
- Type `choco install devtoys` or visit the [chocolatey community package](https://community.chocolatey.org/packages/devtoys/).

## App Permission

DevToys works entirely offline, meaning that none of the data used by the app goes on internet. However, the app requires some other permissions in order to work correctly.

1. `Uses all system resources` - This permission is required for some tools like `PNG / JPEG Compressor` or (upcoming) `On-screen color picker / measurer`, which use a 3rd party Open-Source Win32 process like [Efficient-Compression-Tool](https://github.com/fhanau/Efficient-Compression-Tool).
All the code requiring this permission can be found [here](https://github.com/veler/DevToys/tree/main/src/dev/impl/DevToys.OutOfProcService).

## How to run DevToys

### Using Start Menu

Open Windows start menu, type `DevToys` and press `[Enter]`.

### Using PowerShell

A cool thing about DevToys is that you can start it in command line! For this, simply open a PowerShell command prompt and type
`start devtoys:?tool={tool name}`

For example, `start devtoys:?tool=jsonyaml` will open DevToys and start on the `Json <> Yaml` tool.

Here is the list of tool name you can use:

- `base64` - Base64 Text Encoder/Decoder
- `base64img` - Base64 Image Encoder/Decoder
- `gzip` - GZip Encoder/Decoder
- `hash` - Hash Generator
- `uuid` - UUID Generator
- `loremipsum` - Lorem Ipsum Generator
- `checksum` - Checksum File
- `cronparser` - Cron Parser
- `jsonformat` Json Formatter
- `sqlformat` - SQL Formatter
- `xmlformat` - XML Formatter
- `jsonyaml` - Json <> Yaml
- `jwt` - JWT Decoder
- `colorblind` - Color Blindness Simulator
- `color` - Color Picker & Contrast
- `imgcomp` - PNG/JPEG compressor
- `imageconverter` - Image Converter
- `markdown` - Markdown Preview
- `regex` - Regular Expression Tester
- `time` - Unix Timestamp Converter
- `baseconverter` - Number Base Converter
- `string` - String Utilities
- `url` - URL Encoder/Decoder
- `html` - HTML Encoder/Decoder
- `diff` - Text Comparer
- `xmlvalidator` - XML Validator
- `escape` - Text Escape / Unescape
- `settings` - Settings

## Contribute

See [CONTRIBUTING](CONTRIBUTING.md)
Expand Down Expand Up @@ -188,4 +98,9 @@ DevToys is using a license that permits redistribution of the app as trialware o

### Designers

[Zee-Al-Eid](https://twitter.com/zeealeid)
[Jakub](https://github.com/AlurDesign)

### DevToysMac developer

[ObuchiYuki](https://twitter.com/obuchi_yuki)
Binary file added assets/hero-screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified assets/ms-store-rate.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed assets/screenshots/1.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/All Tools.png
Binary file not shown.
Binary file not shown.
Binary file removed assets/screenshots/Dark/Base 64 Encoder Decoder.png
Binary file not shown.
Binary file not shown.
Binary file removed assets/screenshots/Dark/Checksum Generator.png
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed assets/screenshots/Dark/Cron Expression Parser.png
Binary file not shown.
Binary file not shown.
Binary file removed assets/screenshots/Dark/Guid Generator.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/HTML Encoder Decoder.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/Hash Generator.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/Image Converter.png
Binary file not shown.
Binary file not shown.
Binary file removed assets/screenshots/Dark/JSON Formatter.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/JWT Decoder.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/Lorem Ipsun Generator.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/Markdown Preview.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/Number Base.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/PNG JPEG Compressor.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/Regex Tester.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/SQL Formatter.png
Binary file not shown.
Binary file removed assets/screenshots/Dark/Settings.png
Diff not rendered.
Diff not rendered.
Binary file removed assets/screenshots/Dark/Template.png
Diff not rendered.
Binary file removed assets/screenshots/Dark/Text Diff.png
Diff not rendered.
Binary file removed assets/screenshots/Dark/Text Escape Unescape.png
Diff not rendered.
Binary file removed assets/screenshots/Dark/Timestamp Converter.png
Diff not rendered.
Binary file removed assets/screenshots/Dark/URL Encoder Decoder.png
Diff not rendered.
Binary file removed assets/screenshots/Dark/XML Formatter.png
Diff not rendered.
Binary file removed assets/screenshots/Dark/XML Validator.png
Diff not rendered.
Binary file not shown.
Binary file removed assets/screenshots/Light/All Tools.png
Diff not rendered.
Diff not rendered.
Diff not rendered.
Binary file removed assets/screenshots/Light/Guid Generator.png
Diff not rendered.
Binary file removed assets/screenshots/Light/HTML Encoder Decoder.png
Diff not rendered.
Binary file removed assets/screenshots/Light/Hash Generator.png
Diff not rendered.
Diff not rendered.
Binary file removed assets/screenshots/Light/JSON Formatter.png
Diff not rendered.
Binary file removed assets/screenshots/Light/JWT Decoder.png
Diff not rendered.
Binary file removed assets/screenshots/Light/Markdown Preview.png
Diff not rendered.
Binary file removed assets/screenshots/Light/Number Case.png
Diff not rendered.
Binary file removed assets/screenshots/Light/PNG JPEG Compressor.png
Diff not rendered.
Binary file removed assets/screenshots/Light/Regex Tester.png
Diff not rendered.
Binary file removed assets/screenshots/Light/Settings.png
Diff not rendered.
Diff not rendered.
Binary file removed assets/screenshots/Light/Template.png
Diff not rendered.
Binary file removed assets/screenshots/Light/Text Diff.png
Diff not rendered.
Binary file removed assets/screenshots/Light/URL Encoder Decoder.png
Diff not rendered.
2 changes: 1 addition & 1 deletion chocolatey/DevToys/devtoys.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd">
<metadata>
<id>devtoys</id>
<version>1.0.9.0</version>
<version>0.0.0-preview.0</version>
<packageSourceUrl>https://github.com/veler/DevToys/tree/main/chocolatey/DevToys</packageSourceUrl>
<owners>Rafael Lopez</owners>
<title>DevToys</title>
Expand Down
3 changes: 2 additions & 1 deletion src/Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<CommunityToolkitVersion>8.2.1</CommunityToolkitVersion>
<DotNetVersion>8.0.0</DotNetVersion>
<XUnit>2.5.0</XUnit>
<GirCore>0.5.0-preview.1</GirCore>
<GirCore>0.5.0</GirCore>
</PropertyGroup>
<ItemGroup>
<PackageVersion Include="CommunityToolkit.Common" Version="8.2.2" />
Expand All @@ -15,6 +15,7 @@
<PackageVersion Include="GirCore.Adw-1" Version="$(GirCore)" />
<PackageVersion Include="GirCore.Gtk-4.0" Version="$(GirCore)" />
<PackageVersion Include="GirCore.WebKit-6.0" Version="$(GirCore)" />
<PackageVersion Include="Markdig" Version="0.34.0" />
<PackageVersion Include="Microsoft.AspNetCore.Components.Web" Version="$(DotNetVersion)" />
<PackageVersion Include="Microsoft.AspNetCore.Components.WebView" Version="$(DotNetVersion)" />
<PackageVersion Include="Microsoft.AspNetCore.Components.WebView.Wpf" Version="8.0.3" />
Expand Down
2 changes: 1 addition & 1 deletion src/app/dev/DevToys.Api/DevToys.Api.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<PropertyGroup>
<!-- NuGet package -->
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<Version>2.0.0-pre.1</Version>
<Version>0.0.0-preview.0</Version>
<Authors>veler,btiteux</Authors>
<Description>SDK for developing extensions for DevToys 2.0 and higher</Description>
<PackageProjectUrl>https://devtoys.app</PackageProjectUrl>
Expand Down
Loading

0 comments on commit ba09acf

Please sign in to comment.