How do I get plural content Url using singular content type?

Hi, I am new to Hugo and I am trying to implement a requirement related to the content type. Issue is that I want to declare content type in the singular form (for example “album”, “event”) but I want content URL in the plural form (
something like /albums/newyork/ or /events/newyork/). I am wondering if there is any config setting in Hugo for this kind requirement.

I currently have a content type with the type “albums” and it’s working great and I can open rendered page as http://localhost:1313/albums/newyork/. But, if I declare the type as “album” and I have to stick with the Url like
http://localhost:1313/album/newyork/ which I don’t want.

I am coming from WordPress so it’s kind of learning curve for me to make Hugo work as per my requirement. Any lead or workaround is much appreciated. Thank you.

UPDATE:
To provide additional information, my Hugo project folder looks like following:

content
  albums
    newyork
    newjersey
themes
  journal
    layouts
      albums

The content of above markdown files look like following:

content > albums > newyork > index.md
---
title: New York
name: newyork
date: 2017-08-19T22:36:50-04:00
categories: ["landscape"]
type: albums
description: Nunc blandit nisi ligula magna sodales lectus elementum non. Integer id venenatis velit.
---

content > albums > newjersey > index.md
---
title: New Jersey
name: newjersey
date: 2017-08-19T22:36:50-04:00
categories: ["landscape"]
type: albums
description: Nunc blandit nisi ligula magna sodales lectus elementum non. Integer id venenatis velit.
---

You can change all the permalinks for an entire section in your config. In your case you’d do something like:

permalinks:
  album: /albums/:title/

Let me ask ya, why are you declaring it an “album” content type? I hardly ever need to declare content type, and considering you are new to Hugo, I am wondering if you are creating work for yourself. :slight_smile:

Thanks, Maiki. Defining type helps me to fetch content from different content types using WHERE clause (something like (.Paginate (where .Site.Pages "Type" "post") 6).Pages) and show on a landing page.

On assigning content types:

Hugo assumes that your site will be organized into sections and each section represents a corresponding type. This is to reduce the amount of configuration necessary for new Hugo projects.

If you are taking advantage of this default behavior, each new piece of content you place into a section will automatically inherit the type. Therefore a new file created at content/posts/new-post.md will automatically be assigned the type posts. Alternatively, you can set the content type in a content file’s front matter in the field “type”.

I just wanted to make sure you understood that content has a type by default, in case you are doing an extra step. I don’t quite understand why you would use the singular form in your where filter, rather than the actual name of the section you are using.

I personally haven’t run into a scenario to assign content type, unless one is mixing them in a single section directory. :slight_smile: