<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Huw Fulcher</title>
    <description>The latest articles on DEV Community by Huw Fulcher (@huwfulcher).</description>
    <link>https://dev.to/huwfulcher</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F267862%2Fef88b53f-caf3-472e-b4ed-a0d8a612b5b4.png</url>
      <title>DEV Community: Huw Fulcher</title>
      <link>https://dev.to/huwfulcher</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/huwfulcher"/>
    <language>en</language>
    <item>
      <title>A kinder way to reach our goals</title>
      <dc:creator>Huw Fulcher</dc:creator>
      <pubDate>Tue, 10 Jan 2023 15:26:17 +0000</pubDate>
      <link>https://dev.to/huwfulcher/a-kinder-way-to-reach-our-goals-32f5</link>
      <guid>https://dev.to/huwfulcher/a-kinder-way-to-reach-our-goals-32f5</guid>
      <description>&lt;p&gt;Originally posted on &lt;a href="https://huwfulcher.com/blog/2023/a-kinder-way-to-reach-goals/" rel="noopener noreferrer"&gt;my website&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The best intentions
&lt;/h2&gt;

&lt;p&gt;It's 2023, goals, aspirations and habits are being scribbled down by people round the world. All of this is being framed by a thought, "what should I be &lt;strong&gt;doing&lt;/strong&gt; better this year?". It's a pretty standard thought that everyone has and I'm not saying that it's &lt;strong&gt;bad&lt;/strong&gt; but &lt;strong&gt;that it might hamstring us more than we think&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;For me, the pressure to do things better has had a two fold effect on my mental health and also my ability to get things done. The weight of achieving goals for the year that I am unprepared for and not realistic about traps me in a feedback loop of failure and fear to try and do.&lt;/p&gt;

&lt;h2&gt;
  
  
  3 rules for kinder goals
&lt;/h2&gt;

&lt;p&gt;To try and correct this and have a healthier relationship with my goals this year I've come up with 3 rules:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Explore not do&lt;/li&gt;
&lt;li&gt;Steps not cliffs &lt;/li&gt;
&lt;li&gt;Reflection not metrics&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Explore not do
&lt;/h3&gt;

&lt;p&gt;I've been starting to read &lt;a href="https://www.buildingasecondbrain.com/" rel="noopener noreferrer"&gt;Building a Second Brain&lt;/a&gt; recently and tentatively deciding on whether to use it or if it will send me down the productivity rabbit hole again.&lt;/p&gt;

&lt;p&gt;In the middle of this and also reflecting on how to look after myself and still progress I've been struck by a concept from the book. While it's focused on what information you should capture I think it can be a helpful lens for our goals as well.&lt;/p&gt;

&lt;p&gt;Tiago Forte in the book talks about Richard Feynman and his&lt;br&gt;
&lt;a href="https://fortelabs.com/blog/12-favorite-problems-how-to-spark-genius-with-the-power-of-open-questions/" rel="noopener noreferrer"&gt;12 favourite questions&lt;/a&gt; that acted as a filter for what information he would choose to look into.&lt;/p&gt;

&lt;p&gt;The main characteristics that caught my eye were that they are meant to open ended and spark curiosity. This is a much healthier way to think rather than worrying about missing information that might be useful someday.&lt;/p&gt;

&lt;p&gt;For me the questions I've thought of so far (in no particular order) are:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;How can I maintain a faith-filled marriage and family?&lt;/li&gt;
&lt;li&gt;How can I get the most from the content I consume?&lt;/li&gt;
&lt;li&gt;How can we simplify the web to make consumption more mindful and easier?&lt;/li&gt;
&lt;li&gt;How can we connect better on the internet?&lt;/li&gt;
&lt;li&gt;How do I be a disciple of Christ rather than "doing" Christian things?&lt;/li&gt;
&lt;li&gt;How do we serve our local church better?&lt;/li&gt;
&lt;li&gt;What is my ideal career? Working for a company or working for myself?&lt;/li&gt;
&lt;li&gt;How can I be more consistent in my habits and goals?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This exercise felt liberating. I was giving myself permission to investigate things rather than coming up with ways to do them.&lt;/p&gt;

&lt;p&gt;Then I had the light bulb moment of how this links to goals. While the actual action of working towards a goal is inherently doing something, what if our motivation was exploration rather than "because xyz"?&lt;/p&gt;

&lt;p&gt;Taking one of my quarterly goals of "Eating 1800 calories a day fitting in the right macro nutrients" I could define my motivation as:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"I want to be healthier to be fit and capable and respect my body. I want my mind to be clear to reduce stress on myself and on my family."&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;While this motivation is great, for me it places expectations and pressure on myself. What if instead I made it more interesting?&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"What would it feel like to lose weight and make healthier choices?"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I'm shifting the focus from &lt;strong&gt;doing something because I should to something that motivates me&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Steps not cliffs
&lt;/h3&gt;

&lt;p&gt;Another problem I would have with setting goals was that I was always too ambitious. I would either have too many simple goals or less goals but with impossible heights to achieve.&lt;/p&gt;

&lt;p&gt;I made my progress for the year a bit like climbing a cliff. I've never done climbing but I have it on good authority that it's exhausting, difficult and dangerous the further you go up. &lt;/p&gt;

&lt;p&gt;So when I would be working towards a goal and fail (in something like a habit) I would end up plummeting back down to the bottom, my streak back to zero (I've written about why streaks are bad &lt;a href="https://huwfulcher.com/blog/2023/making-a-chain-isnt-as-important-as-making-an-effort/" rel="noopener noreferrer"&gt;here&lt;/a&gt;). This would play havoc with my self-esteem and motivaiton, what's the point if I never get to the top?&lt;/p&gt;

&lt;p&gt;Instead I've tried streamlining my goals this year. The simpler, the better. Rather than going to the goal's gym and trying to deadlift 400KG I'm going on the crosstrainer and building up my discipline muscles. &lt;/p&gt;

&lt;p&gt;By making my goals a set of steps to climb up, falling off a step isn't going to hurt anywhere near as much as falling off a cliff.&lt;/p&gt;

&lt;h3&gt;
  
  
  Reflection not metrics
&lt;/h3&gt;

&lt;p&gt;This last "not" ties in with exploring rather than doing. If we are trying to "do" a goal we are going to be inclined to measure its success by metrics. How many days in a row? How many days overall? What's the best combination of mood, time of place, alignment of the planets to achieve this goal? Measuring our goals can suck our energy and detract from what we are trying to do.&lt;/p&gt;

&lt;p&gt;If we're asking questions as the motivation for our goals then we need to provide ourselves with some answers. The great thing about this rather than metrics is that it feels more holistic. We're actually spending time reflecting on how our goals are shaping us into what we want to be rather than blindly ploughing on.&lt;/p&gt;

&lt;p&gt;The best analogy I can come up with is that by focusing on metrics, we're "playing" our lives like a video game, how high can we get our score? By reflecting we're instead "inhabiting" the video game of our life, taking in the sights, the sounds, the experience itself.&lt;/p&gt;

&lt;p&gt;It's still a theory but spending more time on reflection than measuring will give us deeper alignment with our goals and with our lives, fulfilling us more.&lt;/p&gt;

&lt;h2&gt;
  
  
  Life isn't a game
&lt;/h2&gt;

&lt;p&gt;This is the longest post I've written ever but in essense it boils down to:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Don't look for the high score, look to live the experience through your goals&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I want to reiterate that I don't think the "doing" mindset is necessarily bad. I think it works for people with a lot of drive but I have found it to be toxic for myself.&lt;/p&gt;

&lt;p&gt;I hope this helps you or at least gives you food for thought. Let me know what you think!&lt;/p&gt;

</description>
      <category>discuss</category>
    </item>
    <item>
      <title>How to integrate TinaCMS with Jekyll</title>
      <dc:creator>Huw Fulcher</dc:creator>
      <pubDate>Thu, 10 Nov 2022 09:31:06 +0000</pubDate>
      <link>https://dev.to/huwfulcher/how-to-integrate-tinacms-with-jekyll-1m6j</link>
      <guid>https://dev.to/huwfulcher/how-to-integrate-tinacms-with-jekyll-1m6j</guid>
      <description>&lt;p&gt;Originally posted at &lt;a href="https://huwfulcher.com/blog/2022/how-to-integrate-tinacms-with-jekyll/"&gt;huwfulcher.com&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://tina.io"&gt;TinaCMS&lt;/a&gt;, the successor to &lt;a href="//forestry.io"&gt;Forestry&lt;/a&gt; has just gone to v1.0, bringing a stable, open-source, git based CMS to static sites. I've just started using TinaCMS with &lt;a href="https://huwfulcher.com"&gt;my site&lt;/a&gt; and I'm actually writing this post using it!&lt;/p&gt;

&lt;p&gt;While there is &lt;a href="https://tina.io/guides/tinacms/non-react-based-ssg/guide/"&gt;some documentation&lt;/a&gt; on adding TinaCMS to a non-NextJS site there are few extra steps that are needed to get it working nicely with Jekyll.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Install TinaCMS
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;code&gt;npx @tinacms/cli@latest init&lt;/code&gt; &lt;em&gt;Note: Docs as of (10/11/2022) specify a --static flag, this is removed and won't work&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;Choose whatever package manager is preferable&lt;/li&gt;
&lt;li&gt;Choose &lt;code&gt;Other&lt;/code&gt; when asked for a framework&lt;/li&gt;
&lt;li&gt;(Optional) Use Typescript, it is recommended&lt;/li&gt;
&lt;li&gt;When asked where public assets are stored specify the top level with &lt;code&gt;/&lt;/code&gt;. Jekyll considers all folders that are not prefixed with &lt;code&gt;_&lt;/code&gt; to be public. Storing tina in the &lt;code&gt;assets&lt;/code&gt; folder will cause issues with pathing later on.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  2. Configure TinaCMS
&lt;/h2&gt;

&lt;h3&gt;
  
  
  a) Update package.json
&lt;/h3&gt;

&lt;p&gt;Replace the content &lt;code&gt;scripts&lt;/code&gt; with the following (or add based on what you need):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;"dev": "tinacms dev -c \"bundle exec jekyll serve\"",
"build": "tinacms build &amp;amp;&amp;amp; jekyll build",
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Run &lt;code&gt;npm run dev&lt;/code&gt; to check no errors are present. You should be able to navigate to &lt;code&gt;localhost:4000/admin/&lt;/code&gt; and see the TinaCMS interface.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;admin&lt;/code&gt; folder should be at the top level of the directory.&lt;/p&gt;

&lt;h3&gt;
  
  
  b) Edit schema
&lt;/h3&gt;

&lt;p&gt;At this point TinaCMS is looking at &lt;code&gt;content/posts&lt;/code&gt; for the &lt;code&gt;.md&lt;/code&gt; files to display and edit. For Jekyll this path should be &lt;code&gt;_posts/&lt;/code&gt;. To fix this we can edit the &lt;code&gt;config.ts&lt;/code&gt; file in &lt;code&gt;.tina&lt;/code&gt;.&lt;/p&gt;

&lt;h4&gt;
  
  
  i. Update media folder
&lt;/h4&gt;

&lt;p&gt;TinaCMS supports uploading and embedding media in your markdown documents from the web editor. The &lt;code&gt;media&lt;/code&gt; property in &lt;code&gt;config.ts&lt;/code&gt; controls where this folder is placed. For Jekyll, this should be under &lt;code&gt;assets&lt;/code&gt;. Change &lt;code&gt;media&lt;/code&gt; to:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;media: {
  tina: {
    mediaRoot: "uploads",
    publicFolder: "assets",
  },
},
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can change the &lt;code&gt;mediaRoot&lt;/code&gt; name to whatever you like, this specifies the folder name under &lt;code&gt;assets&lt;/code&gt;.&lt;/p&gt;

&lt;h4&gt;
  
  
  ii. Update schema path
&lt;/h4&gt;

&lt;p&gt;Under &lt;code&gt;schema&lt;/code&gt; the different types of content are defined as a list of &lt;code&gt;collections&lt;/code&gt;. The only collection present when first creating TinaCMS is &lt;code&gt;post&lt;/code&gt;. Each collection will have a &lt;code&gt;path&lt;/code&gt; variable that defines where TinaCMS should look for the associated files. Update this to &lt;code&gt;_posts&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Once done your &lt;code&gt;collections&lt;/code&gt; should look like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;collections: [
  {
    name: "post",
    label: "Posts",
    path: "_posts",
    fields: [
      {
        type: "string",
        name: "title",
        label: "Title",
        isTitle: true,
        required: true,
      },
      {
        type: "rich-text",
        name: "body",
        label: "Body",
        isBody: true,
      },
    ],
  },
],
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  iii. Tidy up existing posts
&lt;/h4&gt;

&lt;p&gt;Depending on if you're doing a fresh Jekyll install or already have an existing blog, TinaCMS prefers filenames to be &lt;code&gt;.md&lt;/code&gt; rather than &lt;code&gt;.markdown&lt;/code&gt;. Update those accordingly.&lt;/p&gt;

&lt;p&gt;Now when you access &lt;code&gt;localhost:4000/admin/&lt;/code&gt; and got &lt;code&gt;Posts&lt;/code&gt; you should see your existing markdown files.&lt;/p&gt;

&lt;h4&gt;
  
  
  iv. Updating the schema
&lt;/h4&gt;

&lt;p&gt;At this point you can happily use TinaCMS to update or create new markdown files but it will be restricted to only being able to interact with the title and body. If you have any additional frontmatter it will ignore it. To resolve this you can update the &lt;code&gt;fields&lt;/code&gt; section of your &lt;code&gt;config.ts&lt;/code&gt;. Using the starter jekyll site I've created one below:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;fields: [
  {
    type: "string",
    name: "layout",
    label: "Layout",
    required: true,
  },
  { 
    type: "string",
    name: "title",
    label: "Title",
    isTitle: true,
    required: true,
  },
  { 
    type: "datetime",
    name: "date",
    label: "Date",
    required: true,
  },
  { 
    type: "string",
    name: "categories",
    label: "Categories",
  },
  {
    type: "rich-text",
    name: "body",
    label: "Body",
    isBody: true,
  },
],
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Go ahead and try creating a new markdown file using the editor. You should see it appear in &lt;code&gt;_posts&lt;/code&gt; but there's a snag... Jekyll requires a specific naming convention to know which markdown files it should show:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;YEAR-MONTH-DAY-title.md&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Thankfully, TinaCMS allows us to customise our own filename conventions. Add the following to your &lt;code&gt;post&lt;/code&gt; collection just after &lt;code&gt;path&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ui: {
  filename: {
    readonly: false,
    slugify: values =&amp;gt; {
      const date = new Date();
      const day = date.getDate();
      const month = date.getMonth() + 1;
      const year = date.getFullYear();

      let currentDate = `${year}-${month}-${day}`;

      return `${currentDate}-${values?.title?.toLowerCase().replace(/ /g, '-')}`
    }
  }
},
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will take the title you specify, slugify it and prefix it with the current date. When you save files they will be in the correct format for Jekyll to find!&lt;/p&gt;

&lt;h2&gt;
  
  
  Wrapping up
&lt;/h2&gt;

&lt;p&gt;This just scratches the surface of the customisation you can do with TinaCMS. It has the ability to add custom components, fields, templates and a whole lot more. If something in this guide doesn't work get in touch with any of the social links below and I'll see if I can help.&lt;/p&gt;

&lt;h2&gt;
  
  
  References
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://tina.io/guides/tinacms/non-react-based-ssg/guide"&gt;Non-React-based SSG support - TinaCMS Docs&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://tina.io/docs/extending-tina/filename-customization"&gt;Filename customization - TinaCMS Docs&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://tina.io/docs/reference/types"&gt;Field Types - TinaCMS Docs&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>webdev</category>
      <category>tinacms</category>
      <category>jekyl</category>
      <category>tutorial</category>
    </item>
  </channel>
</rss>
