Skip to content

Commit

Permalink
fix commit
Browse files Browse the repository at this point in the history
  • Loading branch information
jookie committed Aug 20, 2024
1 parent f618382 commit beb7234
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
12 changes: 12 additions & 0 deletions app/api/run-script.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
// /jojobot/pages/api/run-script.js
import { exec } from 'child_process';

export default function handler(req, res) {
exec('python3 path_to_your_script.py', (error, stdout, stderr) => {
if (error) {
res.status(500).json({ error: stderr });
} else {
res.status(200).json({ message: 'Script executed successfully' });
}
});
}
1 change: 1 addition & 0 deletions components/jojoTrade/DataDisplay.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
// /jojobot/components/DataDisplay.tsx
'use client'
import { useEffect, useState } from 'react';

function DataDisplay() {
Expand Down

0 comments on commit beb7234

Please sign in to comment.