Skip to content

Commit

Permalink
feat(amd): add 5950 config (#685)
Browse files Browse the repository at this point in the history
  • Loading branch information
njgreb committed Nov 5, 2020
1 parent a293f5e commit 31a3d8f
Show file tree
Hide file tree
Showing 8 changed files with 155 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,8 @@ const store = {
series: {
3070: envOrNumber(process.env.MAX_PRICE_SERIES_3070),
3080: envOrNumber(process.env.MAX_PRICE_SERIES_3080),
3090: envOrNumber(process.env.MAX_PRICE_SERIES_3090)
3090: envOrNumber(process.env.MAX_PRICE_SERIES_3090),
5950: envOrNumber(process.env.MAX_PRICE_SERIES_5950x)
}
},
microCenterLocation: envOrArray(process.env.MICROCENTER_LOCATION, ['web']),
Expand Down
14 changes: 14 additions & 0 deletions src/store/model/amazon.ts
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,20 @@ export const Amazon: Store = {
model: 'tuf oc',
series: '3090',
url: 'https://www.amazon.com/dp/B08HJLLF7G'
},
{
brand: 'amd',
cartUrl: 'https://www.amazon.com/gp/aws/cart/add.html?ASIN.1=B08164VTWH&Quantity.1=1',
model: '5900x',
series: 'ryzen5900',
url: 'https://www.amazon.com/dp/product/B08164VTWH'
},
{
brand: 'amd',
cartUrl: 'https://www.amazon.com/gp/aws/cart/add.html?ASIN.1=B0815Y8J9N&Quantity.1=1',
model: '5950x',
series: 'ryzen5950',
url: 'https://www.amazon.com/dp/product/B0815Y8J9N'
}
],
name: 'amazon'
Expand Down
51 changes: 51 additions & 0 deletions src/store/model/amd.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
import {Store} from './store';

export const AMD: Store = {
labels: {
inStock: {
container: '.btn-shopping-cart',
text: ['add to cart']
},
maxPrice: {
container: '.product-page-description h4',
euroFormat: false
}
},
links: [
{
brand: 'test:brand',
model: 'test:model',
series: 'test:series',
url: 'https://www.amd.com/en/direct-buy/5450881400/us'
},
{
brand: 'amd',
cartUrl: 'https://www.amd.com/en/direct-buy/5450881400/us?add-to-cart=true',
model: '5950x',
series: 'ryzen5950',
url: 'https://www.amd.com/en/direct-buy/5450881400/us'
},
{
brand: 'amd',
cartUrl: 'https://www.amd.com/en/direct-buy/5450881500/us?add-to-cart=true',
model: '5900x',
series: 'ryzen5900',
url: 'https://www.amd.com/en/direct-buy/5450881500/us'
},
{
brand: 'amd',
cartUrl: 'https://www.amd.com/en/direct-buy/5450881600/us?add-to-cart=true',
model: '5800x',
series: 'ryzen5800',
url: 'https://www.amd.com/en/direct-buy/5450881600/us'
},
{
brand: 'amd',
cartUrl: 'https://www.amd.com/en/direct-buy/5450881700/us?add-to-cart=true',
model: '5600x',
series: 'ryzen5600',
url: 'https://www.amd.com/en/direct-buy/5450881700/us'
}
],
name: 'amd'
};
24 changes: 24 additions & 0 deletions src/store/model/bandh.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,30 @@ export const BAndH: Store = {
model: 'tuf oc',
series: '3090',
url: 'https://www.bhphotovideo.com/c/product/1594451-REG/asus_90yv0fd1_m0am00_tuf_gaming_geforce_rtx.html'
},
{
brand: 'amd',
model: '5950x',
series: 'ryzen5950',
url: 'https://www.bhphotovideo.com/c/product/1598372-REG/amd_100_100000059wof_ryzen_9_5950x_3_4.html'
},
{
brand: 'amd',
model: '5900x',
series: 'ryzen5900',
url: 'https://www.bhphotovideo.com/c/product/1598373-REG/amd_100_100000061wof_ryzen_9_5900x_3_7.html'
},
{
brand: 'amd',
model: '5800x',
series: 'ryzen5800',
url: 'https://www.bhphotovideo.com/c/product/1598376-REG/amd_100_100000063wof_ryzen_7_5800x_3_8.html'
},
{
brand: 'amd',
model: '5600x',
series: 'ryzen5600',
url: 'https://www.bhphotovideo.com/c/product/1598377-REG/amd_100_100000065box_ryzen_5_5600x_3_7.html'
}
],
name: 'bandh'
Expand Down
28 changes: 28 additions & 0 deletions src/store/model/bestbuy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,34 @@ export const BestBuy: Store = {
model: 'xlr8 rgb',
series: '3090',
url: 'https://www.bestbuy.com/site/pny-geforce-rtx-3090-24gb-xlr8-gaming-epic-x-rgb-triple-fan-graphics-card/6432657.p?skuId=6432657&intl=nosplash'
},
{
brand: 'amd',
cartUrl: 'https://api.bestbuy.com/click/-/6438942/cart',
model: '5900x',
series: 'ryzen5900',
url: 'https://www.bestbuy.com/site/amd-ryzen-9-5900x-4th-gen-12-core-24-threads-unlocked-desktop-processor-without-cooler/6438942.p?skuId=6438942&intl=nosplash'
},
{
brand: 'amd',
cartUrl: 'https://api.bestbuy.com/click/-/6438941/cart',
model: '5950x',
series: 'ryzen5950',
url: 'https://www.bestbuy.com/site/amd-ryzen-9-5950x-4th-gen-16-core-32-threads-unlocked-desktop-processor-without-cooler/6438941.p?skuId=6438941&intl=nosplash'
},
{
brand: 'amd',
cartUrl: 'https://api.bestbuy.com/click/-/6439000/cart',
model: '5800x',
series: 'ryzen5800',
url: 'https://www.bestbuy.com/site/amd-ryzen-7-5800x-4th-gen-8-core-16-threads-unlocked-desktop-processor-without-cooler/6439000.p?skuId=6439000&intl=nosplash'
},
{
brand: 'amd',
cartUrl: 'https://api.bestbuy.com/click/-/6438943/cart',
model: '5600x',
series: 'ryzen5600',
url: 'https://www.bestbuy.com/site/amd-ryzen-5-5600x-4th-gen-6-core-12-threads-unlocked-desktop-processor-with-wraith-stealth-cooler/6438943.p?skuId=6438943&intl=nosplash'
}
],
name: 'bestbuy'
Expand Down
2 changes: 2 additions & 0 deletions src/store/model/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import {config, defaultStoreData} from '../../config';
import {AMD} from './amd';
import {Adorama} from './adorama';
import {Alternate} from './alternate';
import {AlternateNL} from './alternate-nl';
Expand Down Expand Up @@ -59,6 +60,7 @@ export const storeList = new Map([
[AmazonEs.name, AmazonEs],
[AmazonNl.name, AmazonNl],
[AmazonUk.name, AmazonUk],
[AMD.name, AMD],
[Aria.name, Aria],
[Asus.name, Asus],
[AsusDe.name, AsusDe],
Expand Down
32 changes: 32 additions & 0 deletions src/store/model/newegg.ts
Original file line number Diff line number Diff line change
Expand Up @@ -407,6 +407,38 @@ export const Newegg: Store = {
model: 'tuf oc',
series: '3070',
url: 'https://www.newegg.com/asus-geforce-rtx-3070-tuf-rtx3070-o8g-gaming/p/N82E16814126461'
},
{
brand: 'amd',
cartUrl: 'https://secure.newegg.com/Shopping/AddtoCart.aspx?Submit=ADD&ItemList=N82E16819113664',
itemNumber: '19-113-664',
model: '5900x',
series: 'ryzen5900',
url: 'https://www.newegg.com/amd-ryzen-9-5900x/p/N82E16819113664'
},
{
brand: 'amd',
cartUrl: 'https://secure.newegg.com/Shopping/AddtoCart.aspx?Submit=ADD&ItemList=N82E16819113663',
itemNumber: '19-113-663',
model: '5950x',
series: 'ryzen5950',
url: 'https://www.newegg.com/amd-ryzen-9-5950x/p/N82E16819113663'
},
{
brand: 'amd',
cartUrl: 'https://secure.newegg.com/Shopping/AddtoCart.aspx?Submit=ADD&ItemList=N82E16819113665',
itemNumber: '19-113-664',
model: '5800x',
series: 'ryzen5800',
url: 'https://www.newegg.com/amd-ryzen-9-5900x/p/N82E16819113665'
},
{
brand: 'amd',
cartUrl: 'https://secure.newegg.com/Shopping/AddtoCart.aspx?Submit=ADD&ItemList=N82E16819113666',
itemNumber: '19-113-663',
model: '5600x',
series: 'ryzen5600',
url: 'https://www.newegg.com/amd-ryzen-5-5600x/p/N82E16819113666'
}
],
name: 'newegg',
Expand Down
4 changes: 2 additions & 2 deletions src/store/model/store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ export type Pricing = {
euroFormat?: boolean;
};

export type Series = 'test:series' | '3070' | '3080' | '3090';
export type Series = 'test:series' | '3070' | '3080' | '3090' | 'ryzen5950' | 'ryzen5900' | 'ryzen5800' | 'ryzen5600';

export type Link = {
brand: 'test:brand' | 'asus' | 'evga' | 'gainward' | 'gigabyte' | 'inno3d' | 'kfa2' | 'msi' | 'nvidia' | 'palit' | 'pny' | 'zotac';
brand: 'test:brand' | 'amd' | 'asus' | 'evga' | 'gainward' | 'gigabyte' | 'inno3d' | 'kfa2' | 'msi' | 'nvidia' | 'palit' | 'pny' | 'zotac';
itemNumber?: string;
series: Series;
model: string;
Expand Down

0 comments on commit 31a3d8f

Please sign in to comment.