This commit is contained in:
KernelDeimos 2024-08-29 22:21:07 -04:00
parent 3361043b9d
commit cf24c3dd2a
65 changed files with 97 additions and 76 deletions

22
package-lock.json generated
View File

@ -43,7 +43,7 @@
"dependencies": {
"@heyputer/kv.js": "^0.1.3",
"@heyputer/multest": "^0.0.2",
"@heyputer/putil": "^1.0.0",
"@heyputer/putility": "^1.0.0",
"@opentelemetry/api": "^1.4.1",
"@opentelemetry/auto-instrumentations-node": "^0.43.0",
"@opentelemetry/exporter-trace-otlp-grpc": "^0.40.0",
@ -195,7 +195,7 @@
"webpack-cli": "^5.1.4"
}
},
"asdf/putil": {
"asdf/putility": {
"version": "1.0.0",
"extraneous": true,
"license": "UNLICENSED"
@ -2605,8 +2605,8 @@
"resolved": "src/puter-js",
"link": true
},
"node_modules/@heyputer/putil": {
"resolved": "src/putil",
"node_modules/@heyputer/putility": {
"resolved": "src/putility",
"link": true
},
"node_modules/@heyputer/terminal": {
@ -16446,7 +16446,7 @@
"dependencies": {
"@heyputer/kv.js": "^0.1.3",
"@heyputer/multest": "^0.0.2",
"@heyputer/putil": "^1.0.0",
"@heyputer/putility": "^1.0.0",
"@opentelemetry/api": "^1.4.1",
"@opentelemetry/auto-instrumentations-node": "^0.43.0",
"@opentelemetry/exporter-trace-otlp-grpc": "^0.40.0",
@ -16621,8 +16621,8 @@
"webpack-cli": "^5.1.4"
}
},
"packages/putil": {
"name": "@heyputer/putil",
"packages/putility": {
"name": "@heyputer/putility",
"version": "1.0.0",
"extraneous": true,
"license": "UNLICENSED"
@ -16666,7 +16666,7 @@
"@aws-sdk/client-textract": "^3.621.0",
"@heyputer/kv.js": "^0.1.3",
"@heyputer/multest": "^0.0.2",
"@heyputer/putil": "^1.0.0",
"@heyputer/putility": "^1.0.0",
"@mistralai/mistralai": "^1.0.3",
"@opentelemetry/api": "^1.4.1",
"@opentelemetry/auto-instrumentations-node": "^0.43.0",
@ -16911,10 +16911,10 @@
"version": "1.0.0",
"license": "AGPL-3.0-only"
},
"src/putil": {
"name": "@heyputer/putil",
"src/putility": {
"name": "@heyputer/putility",
"version": "1.0.0",
"license": "UNLICENSED"
"license": "AGPL-3.0-only"
},
"src/strataparse": {
"version": "0.0.0",

View File

@ -71,7 +71,7 @@ doing the useless work that reveals what the useful work is.
## Underlying Constructs
- [putil's README.md](../../packages/putil/README.md)
- [putility's README.md](../../packages/putility/README.md)
- Whenever you see `AdvancedBase`, that's from here
- Many things in backend extend this. Anything that doesn't only doesn't
because it was written before `AdvancedBase` existed.

View File

@ -35,7 +35,7 @@ To function properly, Puter needs **CoreModule**, a database module,
and a storage module.
A module extends
[AdvancedBase](../../../putil/README.md)
[AdvancedBase](../../../putility/README.md)
and implements
an `install` method. The install method has one parameter, a
[Context](../../src/util/context.js)

View File

@ -12,7 +12,7 @@
"@aws-sdk/client-textract": "^3.621.0",
"@heyputer/kv.js": "^0.1.3",
"@heyputer/multest": "^0.0.2",
"@heyputer/putil": "^1.0.0",
"@heyputer/putility": "^1.0.0",
"@mistralai/mistralai": "^1.0.3",
"@opentelemetry/api": "^1.4.1",
"@opentelemetry/auto-instrumentations-node": "^0.43.0",

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const Library = require("./definitions/Library");
const { NotificationES } = require("./om/entitystorage/NotificationES");
const { ProtectedAppES } = require("./om/entitystorage/ProtectedAppES");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class DatabaseModule extends AdvancedBase {
async install (context) {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { Context } = require('./util/context');
const BaseService = require("./services/BaseService");
const useapi = require('useapi');

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class LocalDiskStorageModule extends AdvancedBase {
async install (context) {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class PuterDriversModule extends AdvancedBase {
async install () {}

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class ThirdPartyDriversModule extends AdvancedBase {
// constructor () {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { quot } = require("../util/strutil");
const { TechnicalError } = require("../errors/TechnicalError");
const { print_error_help } = require("../errors/error_help_details");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { quot } = require("../util/strutil");
class ConfigLoader extends AdvancedBase {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { Context } = require('../util/context')
const APIError = require("../api/APIError");
const { AppUnderUserActorType, UserActorType } = require("../services/auth/Actor");

View File

@ -27,7 +27,7 @@ const SystemFSEntryService = require('./storage/SystemFSEntryService.js');
const PerformanceMonitor = require('../monitor/PerformanceMonitor.js');
const { NodePathSelector, NodeUIDSelector, NodeInternalIDSelector } = require('./node/selectors.js');
const FSNodeContext = require('./FSNodeContext.js');
const { AdvancedBase } = require('@heyputer/putil');
const { AdvancedBase } = require('@heyputer/putility');
const { Context } = require('../util/context.js');
const { simple_retry } = require('../util/retryutil.js');
const APIError = require('../api/APIError.js');

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require('@heyputer/putil');
const { AdvancedBase } = require('@heyputer/putility');
const PathResolver = require('../../routers/filesystem_api/batch/PathResolver');
const commands = require('./commands').commands;
const { WorkUnit } = require('../../services/runtime-analysis/ExpectationService');

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { AsyncProviderFeature } = require("../../traits/AsyncProviderFeature");
const { HLMkdir, QuickMkdir } = require("../hl_operations/hl_mkdir");
const { Context } = require("../../util/context");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { id2path } = require("../../helpers");
const { PuterPath } = require("../lib/PuterPath");

View File

@ -1,4 +1,4 @@
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class BroadcastModule extends AdvancedBase {
async install (context) {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const BaseService = require("../../services/BaseService");
const { CLink } = require("./connection/CLink");
const { SLink } = require("./connection/SLink");

View File

@ -1,4 +1,4 @@
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { ChannelFeature } = require("../../../traits/ChannelFeature");
class BaseLink extends AdvancedBase {

View File

@ -1,4 +1,4 @@
const { AdvancedBase } = require('@heyputer/putil');
const { AdvancedBase } = require('@heyputer/putility');
class KeyPairHelper extends AdvancedBase {
static MODULES = {

View File

@ -1,4 +1,4 @@
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const config = require("../../config");
class PuterAIModule extends AdvancedBase {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const config = require("../../config");
class SelfHostedModule extends AdvancedBase {
@ -111,6 +111,18 @@ class SelfHostedModule extends AdvancedBase {
'src/puter-js/dist/puter.dev.js'),
route: '/puter.js/v2',
});
services.registerService('__serve-putilityjs-new', ServeSingleFileService, {
path: path_.resolve(__dirname,
RELATIVE_PATH,
'src/putility/dist/putility.dev.js'),
route: '/putility.js/v1',
});
services.registerService('__serve-gui-js', ServeSingleFileService, {
path: path_.resolve(__dirname,
RELATIVE_PATH,
'src/gui/dist/gui.dev.js'),
route: '/putility.js/v1',
});
}
}

View File

@ -1,4 +1,4 @@
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class TestDriversModule extends AdvancedBase {
async install (context) {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { WeakConstructorFeature } = require("../traits/WeakConstructorFeature");
const { Eq, And } = require("./query/query");
const { Entity } = require("./entitystorage/Entity");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { instance_ } = require("../../monitor/PerformanceMonitor");
const { WeakConstructorFeature } = require("../../traits/WeakConstructorFeature");
const { Property } = require("./Property");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { WeakConstructorFeature } = require("../../traits/WeakConstructorFeature");
class PropType extends AdvancedBase {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { WeakConstructorFeature } = require("../../traits/WeakConstructorFeature");
class Property extends AdvancedBase {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { WeakConstructorFeature } = require("../../traits/WeakConstructorFeature");
const { Context } = require("../../util/context");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { WeakConstructorFeature } = require("../../traits/WeakConstructorFeature");
class Entity extends AdvancedBase {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { BaseES } = require("./BaseES");
const APIError = require("../../api/APIError");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { BaseES } = require("./BaseES");
const APIError = require("../../api/APIError");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { WeakConstructorFeature } = require("../../traits/WeakConstructorFeature");
class Predicate extends AdvancedBase {

View File

@ -87,6 +87,13 @@ router.all('*', async function(req, res, next) {
}
});
}
if (path === '/putility/v1') {
return res.sendFile(_path.join(__dirname, config.defaultjs_asset_path, 'putility.js/v1.js'), function (err) {
if (err && err.statusCode) {
return res.status(err.statusCode).send('Error /putility.js')
}
});
}
}
const db = Context.get('services').get('database').get(DB_READ, 'default');

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const api_error_handler = require("../../api/api_error_handler");
const config = require("../../config");
const { get_user, get_app, id2path } = require("../../helpers");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const NOOP = async () => {};

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const config = require("../config");
const { Context } = require("../util/context");
const { CompositeError } = require("../util/errorutil");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class EngPortalService extends AdvancedBase {
static MODULES = {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { Context } = require("../util/context");
const { ContextAwareFeature } = require("../traits/ContextAwareFeature");
const { OtelFeature } = require("../traits/OtelFeature");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const BaseService = require("./BaseService");
class MapCollection extends AdvancedBase {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class ServicePatch extends AdvancedBase {
patch ({ original_service }) {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class StorageService extends AdvancedBase {
constructor ({ services }) {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
class WSPushService extends AdvancedBase {
static MODULES = {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const BaseService = require("../BaseService");
const { Context } = require("../../util/context");
const config = require("../../config");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { Context } = require("../../util/context");
const { get_user, get_app } = require("../../helpers");
const config = require("../../config");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const BaseService = require("../BaseService");
const { DB_WRITE, DB_READ } = require("./consts");

View File

@ -23,7 +23,7 @@ const { TypedValue } = require("./meta/Runtime");
const BaseService = require("../BaseService");
const { Driver } = require("../../definitions/Driver");
const { PermissionUtil } = require("../auth/PermissionService");
const { Invoker } = require("../../../../putil/src/libs/invoker");
const { Invoker } = require("../../../../putility/src/libs/invoker");
const { get_user } = require("../../helpers");
/**

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { Context } = require("../../util/context");
const { MultiValue } = require("../../util/multivalue");
const { stream_to_buffer } = require("../../util/streamutil");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { BasicBase } = require("../../../../../putil/src/bases/BasicBase");
const { BasicBase } = require("../../../../../putility/src/bases/BasicBase");
const types = require("../types");
const { hash_serializable_object, stringify_serializable_object } = require("../../../util/datautil");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { BasicBase } = require("../../../../../putil/src/bases/BasicBase");
const { BasicBase } = require("../../../../../putility/src/bases/BasicBase");
const { TypeSpec } = require("./Construct");
class RuntimeEntity extends BasicBase {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { is_valid_path } = require("../../filesystem/validation");
const { is_valid_url, is_valid_uuid4 } = require("../../helpers");
const { FileFacade } = require("./FileFacade");

View File

@ -17,7 +17,7 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const TeePromise = require("@heyputer/multest/src/util/TeePromise");
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const { FileTracker } = require("./FileTracker");
const { pausing_tee } = require("../../util/streamutil");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const APIError = require("../../api/APIError");
const { Context } = require("../../util/context");
const BaseService = require("../BaseService");

View File

@ -22,7 +22,7 @@
const axios = require('axios');
const { TeePromise } = require("../../util/promise");
const { AdvancedBase } = require('@heyputer/putil');
const { AdvancedBase } = require('@heyputer/putility');
const FormData = require("form-data");
const { stream_to_the_void, buffer_to_stream } = require('../../util/streamutil');
const BaseService = require('../BaseService');

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
/**
* MutliValue represents a subject with multiple values or a value with multiple

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
/**
* PathBuilder implements the builder pattern for building paths.

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
const { AdvancedBase } = require("@heyputer/putil");
const { AdvancedBase } = require("@heyputer/putility");
const useapi = require("useapi");
const { BaseService } = require("../exports");
const CoreModule = require("../src/CoreModule");

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import { PosixError } from '@heyputer/putil/src/PosixError.js';
import { PosixError } from '@heyputer/putility/src/PosixError.js';
import path_ from 'path-browserify';
let debug = false;

View File

@ -20,7 +20,7 @@ import fs from 'fs';
import path_ from 'path';
import modeString from 'fs-mode-to-string';
import { ErrorCodes, PosixError } from '@heyputer/putil/src/PosixError.js';
import { ErrorCodes, PosixError } from '@heyputer/putility/src/PosixError.js';
// DRY: Almost the same as puter/filesystem.js
function wrapAPIs(apis) {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import { ErrorCodes, PosixError } from '@heyputer/putil/src/PosixError.js';
import { ErrorCodes, PosixError } from '@heyputer/putility/src/PosixError.js';
// DRY: Almost the same as node/filesystem.js
function wrapAPIs(apis) {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import { ErrorCodes, ErrorMetadata, errorFromIntegerCode } from '@heyputer/putil/src/PosixError.js';
import { ErrorCodes, ErrorMetadata, errorFromIntegerCode } from '@heyputer/putility/src/PosixError.js';
import { Exit } from './coreutil_lib/exit.js';
const maxErrorNameLength = Object.keys(ErrorCodes)

View File

@ -18,7 +18,7 @@
*/
import { Exit } from './coreutil_lib/exit.js';
import { resolveRelativePath } from '../../util/path.js';
import { ErrorCodes } from '@heyputer/putil/src/PosixError.js';
import { ErrorCodes } from '@heyputer/putility/src/PosixError.js';
export default {
name: 'touch',

View File

@ -19,7 +19,7 @@
import assert from 'assert';
import { MakeTestContext } from './harness.js'
import builtins from '../../src/puter-shell/coreutils/__exports__.js';
import { ErrorCodes, ErrorMetadata } from '@heyputer/putil/src/PosixError.js';
import { ErrorCodes, ErrorMetadata } from '@heyputer/putility/src/PosixError.js';
export const runErrnoTests = () => {
describe('errno', function () {

View File

@ -16,7 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import { libs } from '@heyputer/putil';
import { libs } from '@heyputer/putility';
const { TeePromise, raceCase } = libs.promise;
const encoder = new TextEncoder();

View File

@ -1,11 +1,13 @@
{
"name": "@heyputer/putil",
"name": "@heyputer/putility",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
"test": "echo \"Error: no test specified\" && exit 1",
"start-webpack": "webpack ./index.js --output-filename putility.js --output-library putility && webpack ./index.js --output-filename putility.dev.js --output-library putility --watch --devtool source-map",
"build": "webpack ./index.js --output-filename putility.js --output-library putility && { echo \"// Copyright 2024 Puter Technologies Inc. All rights reserved.\"; echo \"// Generated on $(date '+%Y-%m-%d %H:%M')\n\"; cat ./dist/putility.js; echo \"\"; } > temp && mv temp ./dist/putility.js"
},
"author": "Puter Technologies Inc.",
"license": "UNLICENSED"
"license": "AGPL-3.0-only"
}