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

individual package yarn.deploy.lock #450

Merged
merged 11 commits into from
Oct 17, 2023
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
2 changes: 1 addition & 1 deletion .github/actions/setup-ts/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ runs:
path: |
./node_modules/
key: node-modules-${{ runner.os }}-v0000-${{ env.NODE_VERSION }}-${{ hashFiles('./yarn.lock') }}-${{ hashFiles('./**/*/package.json') }}
- run: yarn && ./node_modules/.bin/lerna bootstrap
- run: yarn
shell: bash
if: steps.cache-typescript-node-modules.outputs.cache-hit != 'true'
- run: yarn run build
Expand Down
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,10 @@ packages/migration-service/export.json
packages/migration-service/failures.json
migration-docker/data
accounts

.yarn/*
!.yarn/patches
!.yarn/releases
!.yarn/plugins
!.yarn/sdks
!.yarn/versions
8 changes: 8 additions & 0 deletions .yarn/plugins/@yarnpkg/plugin-deploy-lockfiles.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
/* eslint-disable */
module.exports = {
name: "@yarnpkg/plugin-deploy-lockfiles",
factory: function (require) {
var plugin;(()=>{var e={299:e=>{const t="win32"===process.platform,n=t?"\\\\+":"\\/",r=t?"\\\\":"/",i=`((?:[^${r}]*(?:${r}|$))*)`,o=`([^${r}]*)`;e.exports=function(e,{extended:t=!1,globstar:r=!1,strict:s=!1,filepath:a=!1,flags:l=""}={}){let c="",f="",p={regex:"",segments:[]},g=!1,u=!1;const d=[];function w(e,{split:t,last:r,only:i}={}){"path"!==i&&(c+=e),a&&"regex"!==i&&(p.regex+="\\/"===e?n:e,t?(r&&(f+=e),""!==f&&(l.includes("g")||(f=`^${f}$`),p.segments.push(new RegExp(f,l))),f=""):f+=e)}let y,h;for(let n=0;n<e.length;n++)if(y=e[n],h=e[n+1],["\\","$","^",".","="].includes(y))w("\\"+y);else if("/"!==y)if("("!==y)if(")"!==y)if("|"!==y)if("+"!==y)if("@"===y&&t&&"("===h)d.push(y);else if("!"!==y)if("?"!==y)if("["!==y)if("]"!==y)if("{"!==y)if("}"!==y)if(","!==y)if("*"!==y)w(y);else{if("("===h&&t){d.push(y);continue}let s=e[n-1],a=1;for(;"*"===e[n+1];)a++,n++;let l=e[n+1];if(r){a>1&&("/"===s||void 0===s)&&("/"===l||void 0===l)?(w("((?:[^/]*(?:/|$))*)",{only:"regex"}),w(i,{only:"path",last:!0,split:!0}),n++):(w("([^/]*)",{only:"regex"}),w(o,{only:"path"}))}else w(".*")}else{if(g){w("|");continue}w("\\"+y)}else{if(t){g=!1,w(")");continue}w("\\"+y)}else{if(t){g=!0,w("(");continue}w("\\"+y)}else{if(t){u=!1,w(y);continue}w("\\"+y)}else{if(u&&":"===h){n++;let t="";for(;":"!==e[++n];)t+=e[n];"alnum"===t?w("(\\w|\\d)"):"space"===t?w("\\s"):"digit"===t&&w("\\d"),n++;continue}if(t){u=!0,w(y);continue}w("\\"+y)}else{if(t){"("===h?d.push(y):w(".");continue}w("\\"+y)}else{if(t){if(u){w("^");continue}if("("===h){d.push(y),w("(?!"),n++;continue}w("\\"+y);continue}w("\\"+y)}else{if("("===h&&t){d.push(y);continue}w("\\"+y)}else{if(d.length){w(y);continue}w("\\"+y)}else{if(d.length){w(y);let e=d.pop();w("@"===e?"{1}":"!"===e?"([^/]*)":e);continue}w("\\"+y)}else{if(d.length){w(y);continue}w("\\"+y)}else w("\\"+y,{split:!0}),"/"!==h||s||(c+="?");l.includes("g")||(c=`^${c}$`,f=`^${f}$`,a&&(p.regex=`^${p.regex}$`));const x={regex:new RegExp(c,l)};return a&&(p.segments.push(new RegExp(f,l)),p.regex=new RegExp(p.regex,l),p.globstar=new RegExp(l.includes("g")?i:`^${i}$`,l),x.path=p),x}}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={exports:{}};return e[r](o,o.exports,n),o.exports}n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};(()=>{"use strict";n.r(r),n.d(r,{default:()=>o});const e=require("@yarnpkg/core"),t=require("@yarnpkg/fslib");var i=n(299);const o={hooks:{afterAllInstalled:async(n,r)=>{const o=n.workspacesByCwd.get(n.configuration.startingCwd);await r.report.startTimerPromise(`Deployment lockfiles (${o.relativeCwd})`,()=>async function(n,r,o){const s=r.workspacesByCwd.get(r.configuration.startingCwd),a=await e.Cache.find(n,{immutable:!0}),l="."===s.relativeCwd?await async function(e){const t=e.workspacesByCwd.get(e.cwd).manifest.workspaceDefinitions.map(e=>i(e.pattern,{globstar:!0,extended:!0}).regex);return e.workspaces.filter(e=>t.some(t=>t.test(e.relativeCwd)))}(r):[s],c=new Set(l.map(e=>"workspace:"+e.relativeCwd));await Promise.all(l.map(async r=>{const i=t.ppath.join(r.cwd,"yarn.deploy.lock"),s=await async function(t,n,r,i){const{project:o,workspace:s}=await e.Project.find(t,n);o.workspaces=[s],await o.resolveEverything({cache:r,report:new e.ThrowReport});const a="workspace:"+s.relativeCwd;for(const e of o.originalPackages.values())e.reference!=a?i.has(e.reference)&&e.reference:e.reference="workspace:.";for(const e of o.storedDescriptors.values())e.range!=a||(e.range="workspace:.");return o.generateLockfile()}(n,r.cwd,a,c);let l=!1;try{if((await t.xfs.statPromise(i)).size!=s.length)l=!0;else{l=(await t.xfs.readFilePromise(i)).toString()!==s}}catch(e){l=!0}l?(await t.xfs.writeFilePromise(i,s),o.reportInfo(null,e.structUtils.stringifyIdent(r.locator)+" => "+`${"Writing yarn.deploy.lock"}`)):o.reportInfo(null,e.structUtils.stringifyIdent(r.locator)+" => No change")}))}(n.configuration,n,r.report))}}}})(),plugin=r})();
return plugin;
}
};
874 changes: 874 additions & 0 deletions .yarn/releases/yarn-3.6.4.cjs

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
nodeLinker: node-modules

plugins:
- path: .yarn/plugins/@yarnpkg/plugin-deploy-lockfiles.cjs
spec: "https://raw.githubusercontent.com/zaro/yarn-plugin-deploy-lockfiles/main/bundles/%40yarnpkg/plugin-deploy-lockfiles.js"

yarnPath: .yarn/releases/yarn-3.6.4.cjs
23 changes: 12 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ flowchart TD
end

data_credits --DC Burned--> helium_sub_daos

onboarding --issue hotspot, assert location txs--> maker
maker --issue hotspot, assert location--> manager

hnt_price_oracle --HNT Price--> data_credits
dnt_rewards_escrow --> lazy_distributor

manager --Burn DC--> data_credits
manager --Create--> hotspots
manager --Device Count--> helium_sub_daos
Expand Down Expand Up @@ -105,7 +105,7 @@ of particular NFTs as specified by oracles.
### Oracle Architecture

In order to facilitate setting rewards _and_ distributing rewards in a single Solana transaction,
I propose at the url specified in the oracle configuration, supporting `GET` and `POST`
I propose at the url specified in the oracle configuration, supporting `GET` and `POST`

#### GET Request

Expand Down Expand Up @@ -156,33 +156,34 @@ The client should:

## Local Setup

1. Install dependencies
1. Make sure you're using Node 18+

2. Install dependencies

```
$: yarn
$: git submodule init
$: git submodule update
corepack enable
yarn
```

2. Start localnet
3. Start localnet

```
$: TESTING=true anchor localnet
```

3. Start watcher
4. Start watcher

```
$: yarn watch
```

4. Bootstrap localnet
5. Bootstrap localnet

```
$: . ./scripts/bootstrap-localnet.sh
```

5. Run tests against localnet
6. Run tests against localnet

```
$: anchor test --provider.cluster localnet --skip-deploy --skip-local-validator --skip-build
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,6 @@
"shx": "^0.3.4",
"ts-mocha": "^10.0.0",
"typescript": "^5.2.2"
}
},
"packageManager": "[email protected]"
}
4 changes: 1 addition & 3 deletions packages/account-fetch-cache-hooks/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
"name": "@helium/account-fetch-cache-hooks",
"private": false,
"publishConfig": {
"access": "public",
"registry": "https://registry.npmjs.org/"
Expand Down Expand Up @@ -39,8 +38,7 @@
"devDependencies": {
"git-format-staged": "^2.1.3",
"ts-loader": "^9.2.3",
"typescript": "^5.2.2",
"yarn": "^1.22.18"
"typescript": "^5.2.2"
},
"peerDependencies": {
"react": "^16.8 || ^17 || ^18",
Expand Down
Loading
Loading