Add gemini configurations
This commit is contained in:
parent
9ed95658f8
commit
429c1fca38
3 changed files with 36 additions and 3 deletions
|
@ -33,7 +33,7 @@ deploy_links() {
|
||||||
if [ -L "$dest_link" ]; then
|
if [ -L "$dest_link" ]; then
|
||||||
echo "Replacing existing symlink: $dest_link"
|
echo "Replacing existing symlink: $dest_link"
|
||||||
rm "$dest_link"
|
rm "$dest_link"
|
||||||
# If it's a directory or file, back it up.
|
# If it's a directory or file, back it up.
|
||||||
else
|
else
|
||||||
echo "Backing up existing entry: $dest_link -> ${dest_link}.bak"
|
echo "Backing up existing entry: $dest_link -> ${dest_link}.bak"
|
||||||
mv "$dest_link" "${dest_link}.bak"
|
mv "$dest_link" "${dest_link}.bak"
|
||||||
|
@ -57,5 +57,6 @@ deploy_links "$PROJECT_ROOT/bin" "$HOME/bin" "bin"
|
||||||
deploy_links "$PROJECT_ROOT/home" "$HOME" "home"
|
deploy_links "$PROJECT_ROOT/home" "$HOME" "home"
|
||||||
deploy_links "$PROJECT_ROOT/config" "$HOME/.config" "config"
|
deploy_links "$PROJECT_ROOT/config" "$HOME/.config" "config"
|
||||||
deploy_links "$PROJECT_ROOT/wallpapers" "$HOME/media/wallpapers" "wallpapers"
|
deploy_links "$PROJECT_ROOT/wallpapers" "$HOME/media/wallpapers" "wallpapers"
|
||||||
|
deploy_links "$PROJECT_ROOT/gemini" "$HOME/.gemini" "gemini"
|
||||||
|
|
||||||
echo "All deployments complete!"
|
echo "All deployments complete!"
|
||||||
|
|
32
gemini/GEMINI.md
Normal file
32
gemini/GEMINI.md
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
# Gemini Global Configuration
|
||||||
|
|
||||||
|
This document outlines my general preferences for working with Gemini.
|
||||||
|
|
||||||
|
## General Principles
|
||||||
|
|
||||||
|
- **Programming Style**: Please use a functional programming style whenever possible and appropriate for the language.
|
||||||
|
- **Immutability**: Favor immutable data structures and variables where practical.
|
||||||
|
- **Verification**: Do not run tests or build commands. I will handle verification myself.
|
||||||
|
- **Dependencies**: If a new third-party library is needed, propose it and wait for my explicit approval before adding it to the project.
|
||||||
|
- **Documentation**: Use descriptive function and variable names to make code self-documenting. Doc comments should generally only be used for functions that are part of a public or library API.
|
||||||
|
- **Handling Ambiguity**: If a request is unclear or could be interpreted in multiple ways, always stop and ask for clarification.
|
||||||
|
- **Logging**: Unless instructed otherwise, add descriptive logging statements for errors. For logical flows, add messages like "Starting {logic}" and "Successfully completed {logic}".
|
||||||
|
- **API Design**: While not a primary task, prefer `snake_case` for JSON field names. Above all, always remain consistent with the conventions of the current project.
|
||||||
|
|
||||||
|
|
||||||
|
## Language-Specific Guidelines
|
||||||
|
|
||||||
|
### Formatting
|
||||||
|
- **Java**: Adhere to the Google Java Style Guide.
|
||||||
|
- **C++**: Use the default formatting provided by `clangd`.
|
||||||
|
- **Python**: Format code using the `black` code formatter.
|
||||||
|
- **Rust**: Format code using the default `rust-fmt` configuration.
|
||||||
|
|
||||||
|
### Error Handling
|
||||||
|
- **Rust**: Always return a `Result` type instead of panicking.
|
||||||
|
- **Java & Python**: Throw exceptions for error conditions.
|
||||||
|
- **C++**: Use a "Look Before You Leap" (LBYL) approach, checking preconditions to avoid errors.
|
||||||
|
|
||||||
|
### Functional Programming
|
||||||
|
- **Java**: Prioritize the use of functional features like the Stream API.
|
||||||
|
- **C++**: Prioritize the use of modern C++ features that support a functional style, such as lambdas and ranges.
|
|
@ -57,7 +57,7 @@ alias clip2png="xclip -selection clipboard -target image/png -out"
|
||||||
|
|
||||||
load_env() {
|
load_env() {
|
||||||
set -a
|
set -a
|
||||||
. "$1"
|
. "./$1"
|
||||||
set +a
|
set +a
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue