-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
383 changed files
with
4,748 additions
and
79,470 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
function Clear-Dist () { | ||
$distFolders= dir packages/*/dist | ?{$_.PSISContainer} | ||
|
||
foreach ($folder in $distFolders){ | ||
$path = Join-Path -Path $folder.FullName -ChildPath "*" | ||
Remove-Item $path -recurse | ||
Write-Host "Cleaned dist folder in $($path)" | ||
} | ||
} | ||
|
||
function Build () { | ||
npm run build | ||
} | ||
|
||
Write-Host "-- Cleaning files in dist folders --" | ||
Clear-Dist | ||
Write-Host "-- File cleanup finished --" | ||
Write-Host "-- Build process --" | ||
Build | ||
Write-Host "-- Build completed --" | ||
|
||
exit $lastexitcode |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
$dir = dir packages | ?{$_.PSISContainer} | ||
|
||
foreach ($d in $dir){ | ||
$path = Join-Path -Path $d.FullName -ChildPath "" | ||
$name = $d.Name | ||
$root = Get-Location | ||
$fileToCopyPath = "$($root)\.npmrc" | ||
|
||
Write-Host "Copy .npmrc to package $($name) from $($fileToCopyPath) to $($path)" | ||
|
||
Copy-Item $fileToCopyPath $path | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
const ghpages = require('gh-pages'); | ||
const path = require('path'); | ||
|
||
const publishToGhPages = () => { | ||
ghpages.publish( | ||
path.join(__dirname, '../../packages/react-data-grid-examples'), | ||
(err) => { | ||
if (err) throw new Error(err); | ||
} | ||
); | ||
}; | ||
|
||
publishToGhPages(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
const fs = require('fs'); | ||
const path = require('path'); | ||
const scriptArgs = process.argv.slice(2); | ||
const packageName = scriptArgs[0]; | ||
const publish = scriptArgs[1]; | ||
|
||
const getPathToPackageEntry = () => path.join(__dirname, `../../packages/${packageName}/index.js`); | ||
const getPublishEntryData = () => `module.exports = require('./dist/${packageName}');`; | ||
const getDevEntryData = () => "module.exports = require('./src');"; | ||
|
||
const replacePackageEntry = () => { | ||
const entryData = publish ? getPublishEntryData() : getDevEntryData(); | ||
console.log(` --- Overriding ${packageName} entry point ---`); | ||
fs.writeFile( | ||
getPathToPackageEntry(), | ||
entryData, | ||
(err) => { | ||
if (err) throw new Error(errr); | ||
const env = publish ? 'publish' : 'dev'; | ||
console.log(` --- ${packageName} entry point was overriden to ${env}`); | ||
} | ||
); | ||
}; | ||
|
||
replacePackageEntry(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.