Skip to content

Commit

Permalink
adds idx template files to gemini tasks
Browse files Browse the repository at this point in the history
  • Loading branch information
ericwindmill committed Jul 2, 2024
1 parent edc1863 commit 4939b74
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 0 deletions.
53 changes: 53 additions & 0 deletions gemini_tasks/.idx/dev.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{ pkgs }: {
channel = "stable-23.11";
packages = [
pkgs.nodePackages.firebase-tools
pkgs.jdk17
pkgs.unzip
];
idx = {
workspace = {
# Runs when a workspace is first created with this `dev.nix` file
onCreate = {
# Open editors for the following files by default, if they exist.
# The last file in the list will be focused.
default.openFiles = [
"lib/main.dart"
];
# Include other scripts here, as needed, for example:
# installDependencies = "npm install";
};
# To run something each time the workspace is (re)started, use the `onStart` hook
};
previews = {
previews = {
web = {
command = [
"flutter"
"run"
"--machine"
"-d"
"web-server"
"--web-hostname"
"0.0.0.0"
"--web-port"
"$PORT"
];
manager = "flutter";
};
android = {
command = [
"flutter"
"run"
"--machine"
"-d"
"android"
"-d"
"emulator-5554"
];
manager = "flutter";
};
};
};
};
}
6 changes: 6 additions & 0 deletions gemini_tasks/idx-template.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"name": "Flutter Todo list with Gemini",
"description": "A template for a todo list app that integrates with the Gemini API",
"icon": "https://www.gstatic.com/images/branding/productlogos/idx/v1/192px.svg",
"params": []
}
9 changes: 9 additions & 0 deletions gemini_tasks/idx-template.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# No user-configurable parameters
{ pkgs, ... }: {
# Shell script that produces the final environment
bootstrap = ''
cp -rf ${./.} "$out"
chmod -R +w "$out"
rm -rf "$out/.git" "$out/idx-template".{nix,json}
'';
}

0 comments on commit 4939b74

Please sign in to comment.