0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

各言語用遊び場作成

0
Last updated at Posted at 2026-06-16

python遊び場

mkdir pg-python
cd pg-python

# pyproject.toml の作成(ワークスペース定義)
cat << 'EOF' > pyproject.toml
[project]
name = "pg000"
version = "0.1.0"
description = "Python learning workspace"
readme = "README.md"
requires-python = ">=3.12"

[workspace]
members = [
    "pg001",
    "pg002",
]
EOF

# .gitignore の作成
cat << 'EOF' > .gitignore
.venv/
.uv/
__pycache__/
*.pyc
.vscode/
.DS_Store
EOF

# プロジェクトの作成
uv init --app pg001
uv init --app pg002
# パッケージ追加し、pg001でのみ使用する場合
uv add requests --package pg001

# pg001のmain.pyを実行
uv run --package pg001 main.py

rust遊び場

mkdir pg-rust
cd pg-rust

# Cargo.toml の作成(ワークスペース定義)
cat << 'EOF' > Cargo.toml
[workspace]
resolver = "2"

members = [
    "pg001",
    "pg002",
]
EOF

# .gitignore の作成
cat << 'EOF' > .gitignore
/target/
**/target/
.vscode/
.DS_Store
EOF

cargo new pg001 --bin
cargo new pg002 --bin
# チェック
cargo check

# ビルド
cargo build

# pg001実行
cargo run -p pg001

haskell遊び場

mkdir pg-haskell
cd pg-haskell

# Cargo.toml の作成(ワークスペース定義)
cat << 'EOF' > Cargo.toml
[workspace]
resolver = "2"

members = [
    "pg001",
    "pg001",
]
EOF

# .gitignore の作成
cat << 'EOF' > .gitignore
/target/
**/target/
.vscode/
.DS_Store
EOF

# テーマ作成
mkdir -p pg001 && cd pg001 && cabal init -n -p pg001 && cd ..
mkdir -p pg002 && cd pg002 && cabal init -n -p pg002 && cd ..
# 全てbuild
cabal build all

# pg001をrepl
cabal repl pg001

# pg001を実行
cabal run pg001
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?