Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deps(dev): bump aegir from 44.1.4 to 45.0.1 #848

Merged
merged 3 commits into from
Nov 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 14 additions & 11 deletions examples/electron-asar/app.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
/* eslint no-console: 0 */
'use strict'

// @ts-check
const electron = require('electron')
const { path } = require('kubo')
const { create } = require('kubo-rpc-client')
/**
* @type {import('../../src')}
*/
const { createNode, createServer } = require('../../src')
const app = electron.app
const ipcMain = electron.ipcMain
const BrowserWindow = electron.BrowserWindow

const { createController, createServer } = require('ipfsd-ctl')

app.on('ready', () => {
const win = new BrowserWindow({
title: 'loading',
Expand All @@ -23,17 +26,17 @@ ipcMain.on('start', async ({ sender }) => {
sender.send('message', 'starting disposable IPFS')
try {
const s = createServer({
host: '127.0.0.1',
port: 43134
}, {
type: 'go',
ipfsBin: require('go-ipfs').path(),
ipfsHttpModule: require('ipfs-http-client')
type: 'kubo',
rpc: create,
bin: path()
})
await s.start()
const node = await createController({
type: 'go',
ipfsHttpModule: require('ipfs-http-client')
const node = await createNode({
type: 'kubo',
rpc: create,
bin: path()
})
console.log('get id')
sender.send('message', 'get id')
Expand Down
4 changes: 2 additions & 2 deletions examples/electron-asar/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
"private": true,
"main": "./app.js",
"dependencies": {
"go-ipfs": "^0.7.0",
"ipfs-http-client": "^47.0.1",
"kubo": "^0.32.0",
"kubo-rpc-client": "^5.0.0",
"ipfsd-ctl": "file:../.."
},
"devDependencies": {
Expand Down
35 changes: 10 additions & 25 deletions examples/id/id.js
Original file line number Diff line number Diff line change
@@ -1,35 +1,20 @@
/* eslint no-console: 0 */
'use strict'

const { createController } = require('../../src')
const { path } = require('kubo')
const { create } = require('kubo-rpc-client')
/**
* @type {import('../../src')}
*/
const { createNode } = require('../../src')

async function run () {
const node = await createController({
type: 'go',
ipfsBin: require('go-ipfs').path(),
ipfsHttpModule: require('ipfs-http-client')
const node = await createNode({
type: 'kubo',
rpc: create,
bin: path()
})
console.log('alice')
console.log(await node.api.id())
await node.stop()

const nodeJs = await createController({
type: 'js',
ipfsBin: ipfsModule.path(),
ipfsHttpModule
})
console.log('alice')
console.log(await nodeJs.api.id())
await nodeJs.stop()

const nodeProc = await createController({
type: 'proc',
ipfsModule: require('ipfs'),
ipfsHttpModule: require('ipfs-http-client')
})
console.log('bob')
console.log(await nodeProc.api.id())
await nodeProc.stop()
process.exit()
}

Expand Down
17 changes: 11 additions & 6 deletions examples/remote-disposable/remote-disposable.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,23 @@
/* eslint no-console: 0 */
'use strict'

// @ts-check
// Start a remote disposable node, and get access to the api
// print the node id, and stop the temporary daemon

const { createController, createServer } = require('../../src')
const { path } = require('kubo')
const { create } = require('kubo-rpc-client')
/**
* @type {import('../../src')}
*/
const { createNode, createServer } = require('../../src')
const server = createServer()

async function run () {
await server.start()
const node = await createController({
const node = await createNode({
remote: true,
type: 'go',
ipfsBin: require('go-ipfs').path()
type: 'kubo',
bin: path(),
rpc: create
})

console.log(await node.api.id())
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@
"wherearewe": "^2.0.1"
},
"devDependencies": {
"aegir": "^44.1.0",
"aegir": "^45.0.1",
"kubo": "^0.32.0"
},
"browser": {
Expand Down
Loading