Skip to content

Commit

Permalink
Infrastructure Cleanup (#148)
Browse files Browse the repository at this point in the history
* Remove old netlify dot files

* Clean up infrastructure

* Ran prettier on whole project

* Changed husky to pre commit and added tests
  • Loading branch information
raae authored Apr 10, 2022
1 parent 19e360b commit d268620
Show file tree
Hide file tree
Showing 55 changed files with 812 additions and 660 deletions.
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,8 @@ node_modules/
.vscode/
.DS_Store/
.env
public/
.cache/
coverage/
.prefetched-providers.json
*.log
9 changes: 9 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
node_modules/
.vscode/
.DS_Store/
.env
public/
.cache/
coverage/
.prefetched-providers.json
test.js
6 changes: 0 additions & 6 deletions .travis.yml

This file was deleted.

17 changes: 0 additions & 17 deletions gatsby-remark-oembed-md-site/.eslintrc.js

This file was deleted.

4 changes: 0 additions & 4 deletions gatsby-remark-oembed-md-site/.gitignore

This file was deleted.

1 change: 0 additions & 1 deletion gatsby-remark-oembed-md-site/.netlify

This file was deleted.

15 changes: 0 additions & 15 deletions gatsby-remark-oembed-md-site/.travis.yml

This file was deleted.

7 changes: 0 additions & 7 deletions gatsby-remark-oembed-md-site/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,6 @@
"typography": "^0.16.17",
"typography-theme-wordpress-2016": "^0.15.10"
},
"devDependencies": {
"eslint": "^4.19.1",
"eslint-plugin-react": "^7.11.1",
"gh-pages": "^1.2.0",
"prettier": "^1.14.2"
},
"homepage": "https://github.com/raae/gatsby-remark-oembed-example-site#readme",
"keywords": [
"gatsby"
Expand All @@ -46,7 +40,6 @@
"dev": "rm -r -f .cache && gatsby develop",
"lint": "./node_modules/.bin/eslint --ext .js,.jsx --ignore-pattern public .",
"test": "echo \"Error: no test specified\" && exit 1",
"format": "prettier --write 'src/**/*.js' 'src/**/*.md'",
"develop": "gatsby develop",
"build": "rm -r -f .cache && gatsby build",
"deploy": "gatsby build --prefix-paths && gh-pages -d public",
Expand Down
8 changes: 4 additions & 4 deletions gatsby-remark-oembed-md-site/src/components/Bio.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class Bio extends React.Component {
style={{
display: "flex",
marginBottom: rhythm(2.5),
alignItems: "center"
alignItems: "center",
}}
>
<img
Expand All @@ -26,13 +26,13 @@ class Bio extends React.Component {
marginBottom: 0,
width: rhythm(4),
height: rhythm(4),
flexShrink: 0
flexShrink: 0,
}}
/>
<div>
<p
style={{
marginBottom: rhythm(0.4)
marginBottom: rhythm(0.4),
}}
>
Example site for the{" "}
Expand All @@ -43,7 +43,7 @@ class Bio extends React.Component {
</p>
<p
style={{
marginBottom: 0
marginBottom: 0,
}}
>
Created by @raae: <a href="https://twitter.com/raae">Twitter</a>,{" "}
Expand Down
6 changes: 3 additions & 3 deletions gatsby-remark-oembed-md-site/src/components/PageLayout.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,21 @@ const PageLayout = ({ children, title }) => {
marginLeft: "auto",
marginRight: "auto",
maxWidth: rhythm(24),
padding: `${rhythm(1.5)} ${rhythm(3 / 4)}`
padding: `${rhythm(1.5)} ${rhythm(3 / 4)}`,
}}
>
<h1
style={{
...scale(1.5),
marginBottom: rhythm(1.5),
marginTop: 0
marginTop: 0,
}}
>
<Link
style={{
boxShadow: "none",
textDecoration: "none",
color: "inherit"
color: "inherit",
}}
to={"/"}
>
Expand Down
8 changes: 4 additions & 4 deletions gatsby-remark-oembed-md-site/src/components/PostLayout.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,19 @@ const PostLayout = ({ children, next, previous, slug }) => {
marginLeft: "auto",
marginRight: "auto",
maxWidth: rhythm(24),
padding: `${rhythm(1.5)} ${rhythm(3 / 4)}`
padding: `${rhythm(1.5)} ${rhythm(3 / 4)}`,
}}
>
<h3
style={{
fontFamily: "Montserrat, sans-serif",
marginTop: 0,
marginBottom: rhythm(-1)
marginBottom: rhythm(-1),
}}
>
<Link
style={{
boxShadow: "none"
boxShadow: "none",
}}
to={"/"}
>
Expand All @@ -38,7 +38,7 @@ const PostLayout = ({ children, next, previous, slug }) => {
flexWrap: "wrap",
justifyContent: "space-between",
listStyle: "none",
padding: 0
padding: 0,
}}
>
<li>
Expand Down
10 changes: 5 additions & 5 deletions gatsby-remark-oembed-md-site/src/components/layout.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ class Template extends React.Component {
style={{
...scale(1.5),
marginBottom: rhythm(1.5),
marginTop: 0
marginTop: 0,
}}
>
<Link
style={{
boxShadow: "none",
textDecoration: "none",
color: "inherit"
color: "inherit",
}}
to={"/"}
>
Expand All @@ -36,14 +36,14 @@ class Template extends React.Component {
style={{
fontFamily: "Montserrat, sans-serif",
marginTop: 0,
marginBottom: rhythm(-1)
marginBottom: rhythm(-1),
}}
>
<Link
style={{
boxShadow: "none",
textDecoration: "none",
color: "inherit"
color: "inherit",
}}
to={"/"}
>
Expand All @@ -58,7 +58,7 @@ class Template extends React.Component {
marginLeft: "auto",
marginRight: "auto",
maxWidth: rhythm(24),
padding: `${rhythm(1.5)} ${rhythm(3 / 4)}`
padding: `${rhythm(1.5)} ${rhythm(3 / 4)}`,
}}
>
{header}
Expand Down
2 changes: 1 addition & 1 deletion gatsby-remark-oembed-md-site/src/templates/md-post.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const MdPostTemplate = ({ data, pageContext }) => {
<div dangerouslySetInnerHTML={{ __html: post.html }} />
<hr
style={{
marginBottom: rhythm(1)
marginBottom: rhythm(1),
}}
/>
</Layout>
Expand Down
4 changes: 2 additions & 2 deletions gatsby-remark-oembed-md-site/src/utils/typography.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import Wordpress2016 from "typography-theme-wordpress-2016";

Wordpress2016.overrideThemeStyles = () => ({
"a.gatsby-resp-image-link": {
boxShadow: "none"
}
boxShadow: "none",
},
});

delete Wordpress2016.googleFonts;
Expand Down
17 changes: 0 additions & 17 deletions gatsby-remark-oembed-mdx-site/.eslintrc.js

This file was deleted.

4 changes: 0 additions & 4 deletions gatsby-remark-oembed-mdx-site/.gitignore

This file was deleted.

1 change: 0 additions & 1 deletion gatsby-remark-oembed-mdx-site/.netlify

This file was deleted.

15 changes: 0 additions & 15 deletions gatsby-remark-oembed-mdx-site/.travis.yml

This file was deleted.

41 changes: 21 additions & 20 deletions gatsby-remark-oembed-mdx-site/gatsby-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ module.exports = {
author: "raae.codes",
description:
"A site demonstrating the gatsby-remark-oembed plugin used with gatsby-plugin-mdx",
siteUrl: "https://gatsby-remark-oembed-mdx.netlify.com/"
siteUrl: "https://gatsby-remark-oembed-mdx.netlify.com/",
},
pathPrefix: "/",
plugins: [
{
resolve: `gatsby-source-filesystem`,
options: {
path: `${__dirname}/../example-content/posts`,
name: "posts"
}
name: "posts",
},
},
{
resolve: `gatsby-plugin-mdx`,
Expand All @@ -28,38 +28,39 @@ module.exports = {
providers: {
settings: {
Twitter: {
theme: "light" // Use the Twitter light theme
theme: "light", // Use the Twitter light theme
},
Instagram: {
hidecaption: false,
access_token: process.env.INSTAGRAM_ACCESS_TOKEN
}
}
}
}
access_token: process.env.INSTAGRAM_ACCESS_TOKEN,
},
test: "testing",
},
},
},
},
{
resolve: `gatsby-remark-images`,
options: {
maxWidth: 590
}
maxWidth: 590,
},
},
{
resolve: `gatsby-remark-responsive-iframe`,
options: {
wrapperStyle: `margin-bottom: 1.0725rem`
}
}
]
}
wrapperStyle: `margin-bottom: 1.0725rem`,
},
},
],
},
},
`gatsby-transformer-sharp`,
`gatsby-plugin-sharp`,
{
resolve: "gatsby-plugin-typography",
options: {
pathToConfigModule: "src/utils/typography"
}
}
]
pathToConfigModule: "src/utils/typography",
},
},
],
};
4 changes: 1 addition & 3 deletions gatsby-remark-oembed-mdx-site/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,7 @@
},
"devDependencies": {
"eslint": "^4.19.1",
"eslint-plugin-react": "^7.11.1",
"gh-pages": "^1.2.0",
"prettier": "^1.14.2"
"eslint-plugin-react": "^7.11.1"
},
"homepage": "https://github.com/raae/gatsby-remark-oembed-example-site#readme",
"keywords": [
Expand Down
Loading

0 comments on commit d268620

Please sign in to comment.