Skip to content

Commit

Permalink
Merge branch 'windows-working' of github.com:coasys/ad4m into windows…
Browse files Browse the repository at this point in the history
…-working
  • Loading branch information
fayeed committed Oct 9, 2023
2 parents 26b0919 + f074fc3 commit 412f72d
Show file tree
Hide file tree
Showing 5 changed files with 2,813 additions and 2,445 deletions.
2 changes: 1 addition & 1 deletion connect/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
},
"devDependencies": {
"@apollo/client": "3.7.10",
"@perspect3vism/ad4m": "*",
"@perspect3vism/ad4m": "link:../core",
"esbuild": "^0.15.5",
"esbuild-plugin-lit": "^0.0.10",
"graphql-ws": "5.12.0",
Expand Down
2 changes: 1 addition & 1 deletion rust-executor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"url": "https://github.com/perspect3vism/ad4m/issues"
},
"devDependencies": {
"@perspect3vism/ad4m-executor": "*"
"@perspect3vism/ad4m-executor": "link:../core"
},
"dependencies": {}
}
15 changes: 8 additions & 7 deletions setVersion.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ const readline = require('readline-sync');
function replaceVersionLine(content, version, prefix = 'version = ', suffix = '') {
const lines = content.split('\n')
const versionLineIndex = lines.findIndex(line => line.startsWith(prefix))
if (versionLineIndex === -1) throw new Error(`Could not find version line in ${content}`)
const scope = lines[versionLineIndex].substring(prefix.length)
const oldVersion = scope.split('"')[1]
const newVersionLine = `${prefix}"${version}"${suffix}`
Expand Down Expand Up @@ -39,17 +40,17 @@ fs.writeFileSync('package.json', JSON.stringify(rootRepo, null, 2) + '\n')

let ad4mClient;
if (isPreRelease) {
const cli = replaceVersionLine(fs.readFileSync('cli/Cargo.toml', 'utf8'), RUST_VERSION)
cli = replaceVersionLine(fs.readFileSync('cli/Cargo.toml', 'utf8'), RUST_VERSION)
console.log("CLI version: " + cli.oldVersion + " -> " + RUST_VERSION)
ad4mClient = replaceVersionLine(cli.newContent, RUST_VERSION, `ad4m-client = { path = "../rust-client", version = `, ` }`)
console.log(`CLI ad4m-client dep: ${ad4mClient.oldVersion} -> ${RUST_VERSION}`)
// ad4mClient = replaceVersionLine(cli.newContent, RUST_VERSION, `ad4m-client = { path = "../rust-client", version = `, ` }`)
// console.log(`CLI ad4m-client dep: ${ad4mClient.oldVersion} -> ${RUST_VERSION}`)
} else {
const cli = replaceVersionLine(fs.readFileSync('cli/Cargo.toml', 'utf8'), RAW_VERSION)
cli = replaceVersionLine(fs.readFileSync('cli/Cargo.toml', 'utf8'), RAW_VERSION)
console.log("CLI version: " + cli.oldVersion + " -> " + RAW_VERSION)
ad4mClient = replaceVersionLine(cli.newContent, RAW_VERSION, `ad4m-client = { path = "../rust-client", version = `, ` }`)
console.log(`CLI ad4m-client dep: ${ad4mClient.oldVersion} -> ${RAW_VERSION}`)
// ad4mClient = replaceVersionLine(cli.newContent, RAW_VERSION, `ad4m-client = { path = "../rust-client", version = `, ` }`)
// console.log(`CLI ad4m-client dep: ${ad4mClient.oldVersion} -> ${RAW_VERSION}`)
}
fs.writeFileSync('cli/Cargo.toml', ad4mClient.newContent)
fs.writeFileSync('cli/Cargo.toml', cli.newContent)

const connect = JSON.parse(fs.readFileSync('connect/package.json', 'utf8'))
console.log("Connect version: " + connect.version + " -> " + VERSION)
Expand Down
2 changes: 1 addition & 1 deletion ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"dependencies": {
"@apollo/client": "3.7.10",
"@junto-foundation/junto-elements": "^0.5.5",
"@perspect3vism/ad4m": "*",
"@perspect3vism/ad4m": "link:../core",
"@preact/preset-vite": "^2.4.0",
"@tauri-apps/api": "^1.4.0",
"apollo-boost": "^0.4.9",
Expand Down
Loading

0 comments on commit 412f72d

Please sign in to comment.