Skip to content

Commit

Permalink
Adding more docs
Browse files Browse the repository at this point in the history
  • Loading branch information
vickysharma0812 committed Mar 26, 2024
1 parent e6d2112 commit 4a30671
Show file tree
Hide file tree
Showing 148 changed files with 4,311 additions and 345 deletions.
158 changes: 158 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,158 @@
.git
.github
*.out
*.o
build
*/build/*

logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*
.pnpm-debug.log*

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage
*.lcov

# nyc test coverage
.nyc_output

# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# Snowpack dependency directory (https://snowpack.dev/)
web_modules/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional stylelint cache
.stylelintcache

# Microbundle cache
.rpt2_cache/
.rts2_cache_cjs/
.rts2_cache_es/
.rts2_cache_umd/

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variable files
.env
.env.development.local
.env.test.local
.env.production.local
.env.local

# parcel-bundler cache (https://parceljs.org/)
.cache
.parcel-cache

# Next.js build output
.next
out

# Nuxt.js build / generate output
.nuxt
dist

# Gatsby files
.cache/
# Comment in the public line in if your project uses Gatsby and not Next.js
# https://nextjs.org/blog/next-9-1#public-directory-support
# public

# vuepress build output
.vuepress/dist

# vuepress v2.x temp and cache directory
.temp
.cache

# Docusaurus cache and generated files
.docusaurus

# Serverless directories
.serverless/

# FuseBox cache
.fusebox/

# DynamoDB Local files
.dynamodb/

# TernJS port file
.tern-port

# Stores VSCode versions used for testing VSCode extensions
.vscode-test

# yarn v2
.yarn/cache
.yarn/unplugged
.yarn/build-state.yml
.yarn/install-state.gz
.pnp.*

.DS_Store
.$*

~*

build
build/*

*.mtx
*.eps
*.pdf
*.msh
*.geo
*.F90
*.txt
*.gp
*.ps
*.py
*.h5
*.vtu

92 changes: 46 additions & 46 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,49 +5,49 @@
# This job will be called deploy.
#

name: GitHub Pages

on:
push:
branches:
- master
- main
paths:
- ".github/workflows/deploy.yml"
# Review gh actions docs if you want to further define triggers, paths, etc
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on

permissions:
contents: write

jobs:
deploy:
name: Deploy to GitHub Pages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 21
cache: yarn

- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Build website
run: NODE_OPTIONS=--max-old-space-size=4096 yarn build

# Popular action to deploy to GitHub Pages:
# Docs: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
# Build output to publish to the `gh-pages` branch:
publish_dir: ./build
# The following lines assign commit authorship to the official
# GH-Actions bot for deploys to `gh-pages` branch:
# https://github.com/actions/checkout/issues/13#issuecomment-724415212
# The GH actions bot is used by default if you didn't specify the two fields.
# You can swap them out with your own user credentials.
user_name: vickysharma0812
user_email: [email protected]
# name: GitHub Pages
#
# on:
# push:
# branches:
# - master
# - main
# paths:
# - ".github/workflows/deploy.yml"
# # Review gh actions docs if you want to further define triggers, paths, etc
# # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on
#
# permissions:
# contents: write
#
# jobs:
# deploy:
# name: Deploy to GitHub Pages
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
# - uses: actions/setup-node@v3
# with:
# node-version: 21
# cache: yarn
#
# - name: Install dependencies
# run: yarn install --frozen-lockfile
# - name: Build website
# run: NODE_OPTIONS=--max-old-space-size=4096 yarn build
#
# # Popular action to deploy to GitHub Pages:
# # Docs: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus
# - name: Deploy to GitHub Pages
# uses: peaceiris/actions-gh-pages@v3
# with:
# github_token: ${{ secrets.GITHUB_TOKEN }}
# # Build output to publish to the `gh-pages` branch:
# publish_dir: ./build
# # The following lines assign commit authorship to the official
# # GH-Actions bot for deploys to `gh-pages` branch:
# # https://github.com/actions/checkout/issues/13#issuecomment-724415212
# # The GH actions bot is used by default if you didn't specify the two fields.
# # You can swap them out with your own user credentials.
# user_name: vickysharma0812
# user_email: [email protected]
50 changes: 25 additions & 25 deletions .github/workflows/test-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,28 +5,28 @@
# This job will be called test-deploy.
#
#
name: Test deployment

on:
pull_request:
branches:
- master
- main
# Review gh actions docs if you want to further define triggers, paths, etc
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on

jobs:
test-deploy:
name: Test deployment
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 21
cache: yarn

- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Test build website
run: NODE_OPTIONS=--max-old-space-size=4096 yarn build
# name: Test deployment
#
# on:
# pull_request:
# branches:
# - master
# - main
# # Review gh actions docs if you want to further define triggers, paths, etc
# # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on
#
# jobs:
# test-deploy:
# name: Test deployment
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
# - uses: actions/setup-node@v3
# with:
# node-version: 21
# cache: yarn
#
# - name: Install dependencies
# run: yarn install --frozen-lockfile
# - name: Test build website
# run: NODE_OPTIONS=--max-old-space-size=4096 yarn build
45 changes: 45 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# syntax=docker/dockerfile:1

# Stage 1: Base image.
## Start with a base image containing NodeJS so we can build Docusaurus.
FROM node:lts as base
## Disable colour output from yarn to make logs easier to read.
ENV FORCE_COLOR=0
## Enable corepack.
RUN corepack enable
## Set the working directory to `/opt/docusaurus`.
WORKDIR /opt/docusaurus

# Stage 2a: Development mode.
FROM base as dev
## Set the working directory to `/opt/docusaurus`.
WORKDIR /opt/docusaurus
## Expose the port that Docusaurus will run on.
EXPOSE 3000
## Run the development server.
CMD [ -d "node_modules" ] && yarn start || yarn install && yarn start --host 0.0.0.0

# Stage 2b: Production build mode.
FROM base as prod
## Set the working directory to `/opt/docusaurus`.
WORKDIR /opt/docusaurus
## Copy over the source code.
COPY . /opt/docusaurus/
## Install dependencies with `--immutable` to ensure reproducibility.
RUN yarn install --immutable
## Build the static site.
RUN yarn build

# Stage 3a: Serve with `docusaurus serve`.
FROM prod as serve
## Expose the port that Docusaurus will run on.
EXPOSE 3000
## Run the production server.
CMD ["yarn", "serve", "--host 0.0.0.0", "--no-open"]

# Stage 3b: Serve with Caddy.
FROM caddy:2-alpine as caddy
## Copy the Caddyfile.
COPY --from=prod /opt/docusaurus/Caddyfile /etc/caddy/Caddyfile
## Copy the Docusaurus build output.
COPY --from=prod /opt/docusaurus/build /var/docusaurus
31 changes: 31 additions & 0 deletions docs/docs-api/Domain/examples/_ExportMesh_test_1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
This example shows how to convert the domain data from `MSHFile_` format to `HDF5File_` format.

```fortran
PROGRAM main
USE easifemBase
USE easifemClasses
IMPLICIT NONE
TYPE(MSHFile_) :: mshFile
TYPE(HDF5File_) :: hdf5File
! Open mesh file, which is in [[HDF5File_]] file format.
! It is a three setup process; Initiate, open and read.
CALL mshFile%Initiate("./mesh.msh", STATUS="OLD", ACTION="READ")
CALL mshFile%Open()
CALL mshFile%Read()
! Open the [[HDF5File_]] so that we can export data to
! it from mesh file [[MSHFile_]].
CALL hdf5File%Initiate("./mesh.h5", MODE="NEW")
CALL hdf5File%Open()
! Export mesh file to [[HDF5File_]].
CALL mshFile%Export(hdf5=hdf5File, group="")
CALL hdf5File%Deallocate()
CALL mshFile%Deallocate()
END PROGRAM main
```
Loading

0 comments on commit 4a30671

Please sign in to comment.