Updating more references of EOSIO to Antelope (or combined)

This commit is contained in:
Aaron Cox
2023-05-23 21:45:48 -07:00
parent 64fe9cb1f6
commit 7e7258c27c
10 changed files with 19 additions and 15 deletions
+6 -2
View File
@@ -1,6 +1,10 @@
**NOTICE:** This was formerly the `@greymass/eosio` library distributed on [npmjs](https://www.npmjs.com/package/@greymass/eosio). Future distributions will be made using the new organization and namespace, and distributed as `@wharfkit/antelope` again on [npmjs](https://www.npmjs.com/package/@wharfkit/antelope).
To update your codebase, remove the `@greymass/eosio` library and add the `@wharfkit/antelope` library, then replace all instances of `@greymass/eosio` with `@wharfkit/antelope` in all files.
# @wharfkit/antelope
JavaScript library for working with Antelope powered blockchains.
JavaScript library for working with Antelope powered blockchains (formerly EOSIO, still compatible with EOSIO).
Avaiable on npm: https://www.npmjs.com/package/@wharfkit/antelope
@@ -25,7 +29,7 @@ More:
- Using APIs: https://github.com/wharfkit/antelope/blob/master/test/api.ts
- Serialization: https://github.com/wharfkit/antelope/blob/master/test/serializer.ts
- Crypto Operations: https://github.com/wharfkit/antelope/blob/master/test/crypto.ts
- Primative EOSIO Types: https://github.com/wharfkit/antelope/blob/master/test/chain.ts
- Primitive Data Types: https://github.com/wharfkit/antelope/blob/master/test/chain.ts
## Reporting Issues
+1 -1
View File
@@ -12,7 +12,7 @@ const pkg = JSON.parse(fs.readFileSync(path.join(__dirname, 'package.json')))
const license = fs.readFileSync('LICENSE').toString('utf-8').trim()
const banner = `
/**
* EOSIO Core v${pkg.version}
* @wharfkit/antelope v${pkg.version}
* ${pkg.homepage}
*
* @license
+1 -1
View File
@@ -1,4 +1,4 @@
/** Supported EOSIO curve types. */
/** Supported Antelope/EOSIO curve types. */
export enum KeyType {
K1 = 'K1',
R1 = 'R1',
+2 -2
View File
@@ -8,11 +8,11 @@ import {UInt64} from '../'
/** Type representing a name. */
export type NameType = Name | UInt64 | string
/** EOSIO Name */
/** Antelope/EOSIO Name */
export class Name implements ABISerializableObject {
static abiName = 'name'
/** Regex pattern matching a EOSIO name, case-sensitive. */
/** Regex pattern matching a Antelope/EOSIO name, case-sensitive. */
static pattern = /^[a-z1-5.]{0,13}$/
/** The numeric representation of the name. */
+1 -1
View File
@@ -2,7 +2,7 @@ import {Name, NameType, Struct} from '../'
export type PermissionLevelType = PermissionLevel | {actor: NameType; permission: NameType}
/** EOSIO Permission Level, a.k.a "auth". */
/** Antelope/EOSIO Permission Level, a.k.a "auth". */
@Struct.type('permission_level')
export class PermissionLevel extends Struct {
@Struct.field('name') actor!: Name
+3 -3
View File
@@ -34,7 +34,7 @@ export class PrivateKey {
/**
* Create PrivateKey object from a string representation.
* Accepts WIF (5...) and EOSIO (PVT_...) style private keys.
* Accepts WIF (5...) and Antelope/EOSIO (PVT_...) style private keys.
*/
static fromString(string: string, ignoreChecksumError = false) {
try {
@@ -123,7 +123,7 @@ export class PrivateKey {
}
/**
* Return the key in EOSIO PVT_<type>_<base58check> format.
* Return the key in Antelope/EOSIO PVT_<type>_<base58check> format.
*/
toString() {
return `PVT_${this.type}_${Base58.encodeRipemd160Check(this.data, this.type)}`
@@ -141,7 +141,7 @@ function decodeKey(value: string) {
throw new Error(`Expected string, got ${type}`)
}
if (value.startsWith('PVT_')) {
// EOSIO format
// Antelope/EOSIO format
const parts = value.split('_')
if (parts.length !== 3) {
throw new Error('Invalid PVT format')
+2 -2
View File
@@ -74,7 +74,7 @@ export class PublicKey implements ABISerializableObject {
}
/**
* Return EOSIO legacy (`EOS<base58data>`) formatted key.
* Return Antelope/EOSIO legacy (`EOS<base58data>`) formatted key.
* @throws If the key type isn't `K1`
*/
toLegacyString(prefix = 'EOS') {
@@ -84,7 +84,7 @@ export class PublicKey implements ABISerializableObject {
return `${prefix}${Base58.encodeRipemd160Check(this.data)}`
}
/** Return key in modern EOSIO format (`PUB_<type>_<base58data>`) */
/** Return key in modern Antelope/EOSIO format (`PUB_<type>_<base58data>`) */
toString() {
return `PUB_${this.type}_${Base58.encodeRipemd160Check(this.data, this.type)}`
}
+1 -1
View File
@@ -1,5 +1,5 @@
/**
* EOSIO ABI Decoder
* Antelope/EOSIO ABI Decoder
*/
import {ABI, ABIDef, Bytes, BytesType, Variant} from '../chain'
+1 -1
View File
@@ -1,5 +1,5 @@
/**
* EOSIO ABI Encoder
* Antelope/EOSIO ABI Encoder
*/
import {ABI, ABIDef, Bytes, Variant} from '../chain'
import {isInstanceOf} from '../utils'
+1 -1
View File
@@ -15,7 +15,7 @@ export type {
export namespace Serializer {
export const encode = abiEncode
export const decode = abiDecode
/** Create an EOSIO ABI definition for given core type. */
/** Create an Antelope/EOSIO ABI definition for given core type. */
export function synthesize(type: ABISerializableConstructor) {
return synthesizeABI(type).abi
}