mirror of
https://github.com/TeamAmaze/AmazeFileManager.git
synced 2026-10-17 05:08:00 +08:00
Add Github Copilot instructions
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
# Github Copilot guidelines for PR reviews
|
||||
|
||||
This file provides guidance for LLMs to review Amaze File Manager's pull
|
||||
requests.
|
||||
|
||||
## Specific instructions
|
||||
|
||||
In this section are the specific instructions for special cases.
|
||||
|
||||
### try-catch structure
|
||||
|
||||
When writing a try-catch, in most cases, the catch should contain a specific
|
||||
`Exception` subclass, meant to be caught at that point. The `Exception` caught
|
||||
should be thrown by one of the functions called in the try clause. In some
|
||||
cases, the catch has to be generic, for example when the catch has to prevent
|
||||
`Exception`s from crashing a thread.
|
||||
|
||||
When catching an `OutOfMemoryError` the catch clause should make careful use
|
||||
of memory, and should not instantiate new objects. For more information see
|
||||
https://stackoverflow.com/q/24510188.
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
---
|
||||
applyTo: "./app/src/*/res/values*/strings.xml"
|
||||
---
|
||||
# Github Copilot guidelines for translation reviews
|
||||
|
||||
This file provides guidance for LLMs to review Amaze File Manager's pull
|
||||
requests that contain translation files.
|
||||
|
||||
The original files are in English, and translations should follow the original
|
||||
intent, but translators have much leeway in how to express the original intent.
|
||||
|
||||
## Formatting
|
||||
|
||||
All translations should be formated in the same way as the original. One
|
||||
particular case is translations enclosed in Character Data (starting with
|
||||
"<![CDATA[" and ending with "]]>"), the translations should keep the
|
||||
character data markers, as it is needed for Android to parse the string
|
||||
correctly.
|
||||
Reference in New Issue
Block a user