Skip to content

Commit

Permalink
Merge pull request #24 from erikyo/WIP/fse
Browse files Browse the repository at this point in the history
update the template to support the new full site edit
  • Loading branch information
erikyo authored Nov 4, 2023
2 parents c4e7aab + 3262ed0 commit 8cea6ef
Show file tree
Hide file tree
Showing 258 changed files with 38,843 additions and 67,649 deletions.
4 changes: 0 additions & 4 deletions .browserslistrc

This file was deleted.

20 changes: 0 additions & 20 deletions .eslintrc.js

This file was deleted.

49 changes: 49 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs

name: Node.js CI

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [14.x, 16.x, 18.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm install
- run: npm run build --if-present

tests:
name: Tests
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Setup environment to use the desired version of NodeJS
uses: actions/setup-node@v3

- name: Installing NPM dependencies
run: npm install

- name: Starting the WordPress Environment
run: npm run wp-env:start

- name: Running the tests
run: npm run test
36 changes: 35 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,36 @@
# Logs
logs
*.log
npm-debug.log*

# Coverage directory used by tools like istanbul
coverage
artifacts

# Dependency directories
node_modules/
Thumbs.db
vendor/
build/
fonts/

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Output of `npm pack`
*.tgz

# Output of `wp-scripts plugin-zip`
*.zip
*.z7

# dotenv environment variables file
.env

# Jetbrains editor config
.idea

#lockfile
/composer.lock
15 changes: 15 additions & 0 deletions .squash
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[path]
in = src/img
out = img

[.jpg]
compressor = mozjpeg
quality = 85
progressive = true

[.png]
compressor = webp
quality = 80

[.svg]
options = CleanupAttrs, RemoveDoctype, RemoveXMLProcInst, RemoveComments, RemoveMetadata, RemoveXMLNS, RemoveEditorsNSData, RemoveTitle, RemoveDesc, RemoveUselessDefs, RemoveEmptyAttrs, RemoveHiddenElems, RemoveEmptyContainers, RemoveEmptyText, RemoveUnusedNS, ConvertShapeToPath, SortAttrs, MergePaths, SortDefsChildren, RemoveDimensions, RemoveStyleElement, RemoveScriptElement, InlineStyles, removeViewBox, removeElementsByAttr, cleanupIDs, convertColors, removeRasterImages, removeUselessStrokeAndFill, removeNonInheritableGroupAttrs
10 changes: 10 additions & 0 deletions .wp-env.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"core": null,
"themes": ["./"],
"config": {
"WP_DEBUG": true,
"SCRIPT_DEBUG": true,
"FS_METHOD": "direct",
"WP_DEFAULT_THEME": "modul-r"
}
}
78 changes: 78 additions & 0 deletions .wpcs.xml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
<?xml version="1.0"?>
<ruleset name="WordPress Coding Standards based custom ruleset for your plugin">
<description>Generally-applicable sniffs for WordPress plugins.</description>

<arg name="cache"/>

<!-- Set the memory limit to 256M.
For most standard PHP configurations, this means the memory limit will temporarily be raised.
Ref: https://github.com/squizlabs/PHP_CodeSniffer/wiki/Advanced-Usage#specifying-phpini-settings
-->
<ini name="memory_limit" value="256M"/>

<!-- How to scan -->
<!-- Usage instructions: https://github.com/squizlabs/PHP_CodeSniffer/wiki/Usage -->
<!-- Annotated ruleset: https://github.com/squizlabs/PHP_CodeSniffer/wiki/Annotated-ruleset.xml -->

<arg value="sp"/> <!-- Show sniff and progress -->
<arg name="basepath" value="./"/><!-- Strip the file paths down to the relevant bit -->
<arg name="extensions" value="php"/>
<arg name="parallel" value="20"/><!-- Enables parallel processing when available for faster results. -->

<!-- Rules: Check PHP version compatibility -->
<!-- https://github.com/PHPCompatibility/PHPCompatibility#sniffing-your-code-for-compatibility-with-specific-php-versions -->
<config name="testVersion" value="5.6"/>

<!-- Rules: WordPress Coding Standards -->
<!-- https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards -->
<!-- https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards/wiki/Customizable-sniff-properties -->
<config name="minimum_supported_wp_version" value="7.1"/>

<!-- https://github.com/PHPCompatibility/PHPCompatibilityWP -->
<rule ref="PHPCompatibilityWP"/>

<rule ref="WordPress-Extra"/>
<rule ref="WPThemeReview"/>
<rule ref="WordPress-VIP-Go"/>
<rule ref="WordPressVIPMinimum"/>
<rule ref="WordPress-Docs"/>
<rule ref="VariableAnalysis"/>

<rule ref="WordPress.WP.I18n">
<properties>
<property name="text_domain" type="array">
<element value="modul-r"/>
</property>
</properties>
</rule>

<rule ref="WordPress.NamingConventions.PrefixAllGlobals">
<properties>
<property name="prefixes" type="array">
<element value="modul-r"/>
</property>
</properties>
</rule>

<rule ref="WordPress.WP.I18n">
<exclude name="WordPress.WP.I18n.NonSingularStringLiteralDomain"/>
</rule>

<!-- Exclude the 'empty' index files from some documentation checks - https://github.com/WordPress/WordPress-Coding-Standards/issues/451 -->
<rule ref="Squiz.Commenting.FileComment">
<exclude-pattern>*/index\.php</exclude-pattern>
</rule>
<rule ref="Squiz.Commenting.InlineComment.NoSpaceBefore">
<exclude-pattern>*/index\.php</exclude-pattern>
</rule>

<!-- What to scan -->
<file>.</file>
<exclude-pattern>/dist/*</exclude-pattern>
<exclude-pattern>/src/*</exclude-pattern>
<exclude-pattern>/node_modules/*</exclude-pattern>
<exclude-pattern>/vendor/*</exclude-pattern>
<exclude-pattern>*.asset.php</exclude-pattern>
<exclude-pattern>*.js</exclude-pattern>

</ruleset>
38 changes: 0 additions & 38 deletions 404.php

This file was deleted.

45 changes: 0 additions & 45 deletions archive.php

This file was deleted.

Loading

0 comments on commit 8cea6ef

Please sign in to comment.